Rolling update strategy
Deployments update Pod templates through ReplicaSets. maxSurge controls temporary extra replicas and maxUnavailable limits reduced available capacity. Available capacity still depends on readiness and resource supply. A new image that cannot start can stall the rollout while some old replicas remain. For example, a two-replica app with maxUnavailable 0 needs enough spare capacity to add a new ready replica before removing an old one.
A two-replica app with maxUnavailable 0 needs enough spare capacity to add a new ready replica before removing an old one.
A Deployment changes its Pod template to a new image. A new ReplicaSet creates Pods while old replicas are reduced according to the rolling strategy. maxSurge allows additional replicas, and maxUnavailable limits unavailable capacity. New Pods must become suitably ready before the rollout can meet availability goals; sufficient node resources and image access are prerequisites.
A rollout advances to a new template. Surge is temporary extra replica capacity. Availability depends on observed readiness and relevant timing. A strategy requesting zero unavailable replicas can stall when there is no room for a replacement. Conversely, allowing too many unavailable replicas can interrupt users. Rolling behavior cannot guarantee application compatibility, database consistency, or successful external effects. Observe updated and available counts, bounded rollout status, events, and actual requests. A valid image string and accepted template merely begin the process; they do not establish a completed release.
A two-replica app with maxUnavailable 0 needs enough spare capacity to add a new ready replica before removing an old one.
Do not overlook this operational distinction: A new image that cannot start can stall the rollout while some old replicas remain.