CI/CDKubernetes
Rolling, blue-green or canary: choosing a deployment strategy
All three replace an old version with a new one. They differ in how much traffic meets a bad release, and in what each one needs from your platform.

Rolling: a few pods at a time
RollingUpdate is the default strategy of a Kubernetes Deployment. It gradually scales down the old ReplicaSet and scales up the new one. maxSurge caps how many Pods may exist above the desired count, and maxUnavailable caps how many may be unavailable while the update runs. Both default to 25%.
strategy:
type: RollingUpdate
rollingUpdate:
maxSurge: 1
maxUnavailable: 1While the update runs, old Pods and new Pods serve traffic side by side. For an application that cannot tolerate two versions, for example because of database schema incompatibilities, Kubernetes points to the Recreate strategy, which causes downtime.
Blue-green: two environments, one switch
Argo Rollouts describes a blue-green deployment as the new and the old version deployed at the same time, with only the old version receiving production traffic. Tests can run against the new version before live traffic is switched to it. The switch is all or nothing, and it needs no traffic manager.
Canary: a small share first
In a canary deployment a subset of users gets the new version and all other traffic stays on the old one. In plain Kubernetes, a stable and a canary Deployment share a label that one Service selects, and the replica counts set the traffic ratio. Argo Rollouts integrates with ingress controllers and service meshes to shift traffic by weight, and it can query metrics providers to drive automated promotion or rollback.
How to choose
- Rolling. Kubernetes' comparison of update strategies lists it as best for most workloads.
- Blue-green. Argo Rollouts calls it the easier strategy to start with, and the more limited one.
- Canary. Kubernetes lists it for high-risk changes that require production validation. Argo Rollouts adds that not all applications can run different versions in parallel.
What every strategy needs
- Database changes that work with both versions. DORA's parallel change pattern never mutates an existing database object. Add the new column beside the old one, then let the new application version move over.
- Readiness probes that tell the truth. A readiness probe determines when a container is ready to accept traffic. On failure, Kubernetes takes the Pod's IP address out of the EndpointSlices of every Service that matches the Pod.
- A rollback you have run.
kubectl rollout undo deployment/nginx-deploymentis the documented command that rolls a Deployment back to its previous revision.
Sources
Want a second pair of eyes on yours? We do this work for a living.
More guides

Self-hosted runners: the security rules
CI/CD · 4 min read
Ephemeral runners, runner groups by trust level, limited egress and no stored cloud keys.

Semantic versioning and automated releases
CI/CD · 5 min read
The semver rules, commit messages that carry the bump, and two tools that cut the release.

Trunk-based development: short branches and small merges
CI/CD · 4 min read
One shared branch, branches that live a couple of days, and flags that hide unfinished work.