Rolling Updates

The rollingUpdate option expects the Kubernetes configuration for rolling updates.

rollingUpdate:
enabled: true
maxSurge: "100%"
maxUnavailable: "50%"

For Deployments

The following fields are supported for Deployments (none of the containers mounts any persistent volumes):

  • enabled
  • maxSurge
  • maxUnavailable

Example: Enabling Rolling Updates for Deployments

containers:
- image: john/appbackend
rollingUpdate:
enabled: true
maxSurge: "100%"
maxUnavailable: "50%"

enabled

The enabled option expects a boolean and defines if rolling updates should be enabled or disabled.

Default Value For enabled

enabled: false
info

If enabled = true, the Kubernetes rolling update type will be set to RollingUpdate (default: Recreate).

maxSurge

The maxSurge option expects a string defining a percentage of pods that can be created above the desired number of replicas.

Default Value For maxSurge

maxSurge: "25%"

maxUnavailable

The maxUnavailable option expects a string defining a percentage of pods that can be unavailable during an update.

Default Value For maxUnavailable

maxUnavailable: "0%"

For StateFulSets

The following fields are supported for StatefulSets (at least one of the containers mounts a persistent volume):

  • enabled
  • partition

enabled

The enabled option expects a boolean and defines if rolling updates should be enabled or disabled.

Default Value For enabled

enabled: false
info

If enabled = true, the Kubernetes rolling update type will be set to RollingUpdate (default: Recreate).

partition

The partition option expects an integer that tells Kubernetes to only update pods with an ordinal number greater than or equal this value.

Default Value For partition

partition: 1