Skip to main content
>_ supraj.dev
TOPIC DEVOPS
Rollbacks undoing a bad release
IN 10 SECONDS

The process of reverting a system to its last known stable state. Reverting deployments can be achieved by redeploying the previous build artifact or modifying DNS/routing selectors.

GOTCHA If database schemas were migrated, rolling back code without rolling back database migrations can break queries and corrupt active user transactions.
HOW A DEPLOYMENT ROLLBACK FLOWS
01 Outage detection alerts fire because error rates spike post-deployment.
02 Rollback command deployer triggers rollback, pointing active configuration back to previous stable release tag.
03 Target Swap system starts launching stable pods while gracefully terminating broken version pods.
04 Verification metrics stabilize back to normal baseline range.
POKE IT YOURSELF
kubectl rollout undo deployment/my-app — revert a Kubernetes deployment rollout immediately
git revert COMMIT_SHA — create a new commit that undoes the changes of a broken commit