cd D:\Projects\HMSCC
git add .
git commit -m "Production: Fix dependencies and optimize for Render"
git push origin main- Go to https://render.com/dashboard
- Click + New β Web Service
- Search and select: HarshMrigank/HMSCC
- Fill in:
- Name:
hmscc-backend - Environment: Docker β (important)
- Region:
Oregon - Branch:
main
- Name:
- Click Create Web Service
- Click your service in Render
- Go to Logs tab
- Wait for status to show Live (green)
- Test health endpoint:
https://your-service-name.onrender.com/health - Should return:
{"status":"ok","compiler":"available"}
β Your backend is now live on Render! π
| Component | Status | Location |
|---|---|---|
| Frontend | β Running | Port 5174 (React + CodeMirror) |
| Backend | β Running | Port 5001 (Node.js/Express) |
| Compiler | β Ready | C++11 with CMake |
| Docker | β Optimized | Multi-stage build for Render |
# Frontend
cd frontend && npm install && npm run dev # Port 5174
# Backend (new terminal)
cd backend && npm install && npm start # Port 5001β
Dependencies: Added 9 missing CodeMirror packages (@codemirror/language, lang-css, lang-html, autocomplete, language-data, axios)
β
Dockerfile: Production-optimized (port 5001, compiler path, npm ci)
β
Frontend: No errors, all imports resolve
β
Backend: Fully operational, health check working
Render automatically detects:
- β Dockerfile in repository root
- β Port 5001 from EXPOSE directive
- β Start command from CMD directive
- β Multi-stage build process
git push β GitHub β Render webhook β Docker build β
Deploy container β Live on Render
Auto-Deploy: Every git push = auto redeploy
curl https://your-service-name.onrender.com/health
# {"status":"ok","compiler":"available"}curl -X POST https://your-service-name.onrender.com/compile `
-H "Content-Type: application/json" `
-Body '{"code":"arena () { speak 42; }"}'
# {"success":true,"output":"42\n",...}Open: https://your-service-name.onrender.com/health
| Issue | Solution |
|---|---|
| Build fails | Check Build Logs, fix error, git push |
| Service won't start | Check Logs, verify environment |
| API doesn't respond | Wait 30 sec, check /health |
| Port errors | Render manages ports automatically |
| Git push fails | Verify credentials |
HMSCC/
βββ dockerfile β Main deployment file
βββ frontend/ β React (port 5174)
β βββ package.json
β βββ src/
βββ backend/ β Node.js API (port 5001)
β βββ package.json
β βββ server.js
βββ compiler/ β C++ compiler
β βββ CMakeLists.txt
βββ README.md β This file
βββ HMSCC_TEST_CASES.md β Example programs
Initial: git push β Render builds β Deploy (5-10 min)
Future: git push β Render auto-redeploys (2-5 min)
No manual steps needed after first deployment!
| Plan | Cost | Auto-on | Use Case |
|---|---|---|---|
| Free | $0/month | No (spins down) | Development |
| Starter | $7/month | Yes | Production |
GET /health β {"status":"ok","compiler":"available"}
POST /compile β {"code":"...hmscc code..."} β
{"success":true,"output":"...","errors":[]}
arena (main), speak (print), listen (input), let (var), loop, check (if)
arena () {
speak 42;
}
See HMSCC_TEST_CASES.md for more examples.
# Push to GitHub
git add . && git commit -m "msg" && git push origin main
# Frontend dev
cd frontend && npm run dev
# Backend
cd backend && npm start
# Docker test
docker build -t hmscc . && docker run -p 5001:5001 hmscc| Link | Purpose |
|---|---|
| https://github.com/HarshMrigank/HMSCC | Repository |
| https://render.com/dashboard | Deploy here |
| http://localhost:5174 | Frontend local |
| http://localhost:5001 | Backend local |
- Frontend works on localhost:5174
- Backend works on localhost:5001
- Health endpoint responds
- All code committed
- Ready to git push
π Follow the Quick Start at the top! π
Status: β Production Ready | Deploy Time: ~15 minutes | Updated: Jan 30, 2026