Deployments¶
How we ship code to production.
TL;DR¶
Merge to main → CI runs → auto-deploy to staging → manual approval → production.
Prerequisites¶
- Your PR has been reviewed and approved
- CI is green on your branch
- You've tested locally against a staging-like config
The flow¶
- Merge the PR to
main. - CI builds the artifact and deploys to staging automatically.
- Smoke-test staging. Link to the staging URL is posted in
#deploys. - Click Approve on the production deploy in GitHub Actions.
- Watch the dashboards for 10 minutes. If anything looks off, roll back.
- Branch from
main, make the minimal fix. - Open a PR tagged
hotfix. This skips the usual review SLA — still needs one approval, but anyone on-call can approve. - Merge and deploy as above, but skip staging soak time.
- File a follow-up issue for the real fix if the hotfix was a band-aid.
Rolling back¶
Roll back first, debug second
If production is unhealthy, roll back before investigating. A bad deploy on production costs the team more than a quick revert ever will.
Two options:
- Redeploy the previous tag from the Actions tab. Usually takes about 2 minutes.
- Revert the merge commit on
mainand let CI redeploy. Use this when you also want to preserve the revert in history.
Who can deploy¶
TODO: list the team / role that can approve production deploys.