Render Deployment Troubleshooting
Quick reference for debugging failed deploys and env var issues on Render.
Env var changes and restarts
If you updated an env var (e.g. DISCORD_REDIRECT_URI) and the service did not restart:
Render lets you choose deploy behavior when saving env vars in the Dashboard:
- Save only — Variables are saved but the service keeps running with the old values until the next deploy.
- Save and deploy — Redeploys the existing build with the new variables.
- Save, rebuild, and deploy — Full rebuild and deploy.
If you chose Save only, the API (or agent) will not pick up the new value until you trigger a deploy.
Fix: Manually deploy from the Render Dashboard → your service → Manual Deploy, or push a commit to trigger auto-deploy. For ledgerline-api only, you can run:
RENDER_API_KEY=... pnpm render:deploy
pnpm render:watchbuild --logs
Checking deploy status and logs
The Render API sometimes returns empty deploy logs for failed deploys. When render:status --logs shows no log lines, open the Render Dashboard → service → Logs or Events for full build/release output.
CLI (no MCP)
# Status for API and Datadog agent (latest deploy)
RENDER_API_KEY=... pnpm render:status
# With recent deploy logs
RENDER_API_KEY=... pnpm render:status --logs
# Only API or only agent
RENDER_API_KEY=... pnpm render:status api --logs
RENDER_API_KEY=... pnpm render:status agent --logs
RENDER_API_KEY=... pnpm render:status all --logs
Watch a deploy in progress
RENDER_API_KEY=... pnpm render:watchbuild
RENDER_API_KEY=... pnpm render:watchbuild --logs
Render MCP (Cursor)
The Render MCP can tail logs and list deploys, but requires a workspace to be selected first.
- Use the Render MCP to select your workspace (ask the assistant to help).
- Then use
/taillogsorlist_logs/list_deploys/get_deployfor the target service.
Services:
ledgerline-api— Web APIdatadog-agent— Private service for APM/DogStatsD
Common failure modes
| Symptom | Cause | Fix |
|---|---|---|
| API didn’t restart after env change | "Save only" for env vars | Manual Deploy or push |
build_failed | Build errors (deps, tsc, tsup) | Check build logs; fix locally |
update_failed | Build succeeded, start failed | Check deploy logs for startup errors |
Invalid OAuth2 redirect_uri | DISCORD_REDIRECT_URI ≠ Discord config | Match URI in Discord app to DISCORD_REDIRECT_URI |
| datadog-agent failed | Docker build / DD_API_KEY | Set DD_API_KEY on agent; check Dockerfile build |
unable to reliably determine the host name | Render container has no resolvable hostname | Set DD_HOSTNAME in Dockerfile or Render env |
connection refused :5001 (system-probe) | Process agent needs system-probe; Render has none | Set DD_PROCESS_AGENT_ENABLED=false |
Dynamic require of "hot-shots" is not supported | ESM bundle; dep required dynamically | Use import; add dep to tsup external |
/info and /api/info
Debug endpoint returning deployment metadata, masked env vars, git branch/SHA, and build info. Use to quickly verify what is running in each environment.
curl https://your-service.onrender.com/api/info
Returns JSON: build, deployment (Render platform, service, branch, commit), env (masked values).
RENDER_API_KEY
Get your API key from Render Dashboard → Account Settings → API Keys. Set RENDER_API_KEY in .env or export it before running render:status, render:watchbuild, or render:deploy.