diff --git a/ceph-client/templates/deployment-mds.yaml b/ceph-client/templates/deployment-mds.yaml index debc83aad..dd4ae8426 100644 --- a/ceph-client/templates/deployment-mds.yaml +++ b/ceph-client/templates/deployment-mds.yaml @@ -33,6 +33,7 @@ spec: selector: matchLabels: {{ tuple $envAll "ceph" "mds" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 6 }} +{{ tuple $envAll | include "helm-toolkit.snippets.kubernetes_upgrades_deployment" | indent 2 }} template: metadata: name: ceph-mds diff --git a/ceph-client/templates/deployment-mgr.yaml b/ceph-client/templates/deployment-mgr.yaml index f7e17c057..92810b913 100644 --- a/ceph-client/templates/deployment-mgr.yaml +++ b/ceph-client/templates/deployment-mgr.yaml @@ -34,7 +34,7 @@ spec: matchLabels: {{ tuple $envAll "ceph" "mgr" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 6 }} strategy: - type: Recreate + type: {{ .Values.pod.updateStrategy.mgr.type }} template: metadata: labels: diff --git a/ceph-client/values.yaml b/ceph-client/values.yaml index 6be76f8d7..ca28d014a 100644 --- a/ceph-client/values.yaml +++ b/ceph-client/values.yaml @@ -106,6 +106,17 @@ pod: replicas: mds: 2 mgr: 2 + lifecycle: + upgrades: + deployments: + pod_replacement_strategy: RollingUpdate + revision_history: 3 + rolling_update: + max_surge: 25% + max_unavailable: 25% + updateStrategy: + mgr: + type: Recreate affinity: anti: type: diff --git a/ceph-mon/templates/daemonset-mon.yaml b/ceph-mon/templates/daemonset-mon.yaml index a53117ad7..0bf3f487c 100644 --- a/ceph-mon/templates/daemonset-mon.yaml +++ b/ceph-mon/templates/daemonset-mon.yaml @@ -59,6 +59,7 @@ spec: selector: matchLabels: {{ tuple $envAll "ceph" "mon" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 6 }} +{{ tuple $envAll "mon" | include "helm-toolkit.snippets.kubernetes_upgrades_daemonset" | indent 2 }} template: metadata: labels: diff --git a/ceph-mon/values.yaml b/ceph-mon/values.yaml index 42dbff30b..00a36be03 100644 --- a/ceph-mon/values.yaml +++ b/ceph-mon/values.yaml @@ -83,6 +83,14 @@ pod: dns_policy: "ClusterFirstWithHostNet" replicas: mon_check: 1 + lifecycle: + upgrades: + daemonsets: + pod_replacement_strategy: RollingUpdate + mon: + enabled: true + min_ready_seconds: 0 + max_unavailable: 1 affinity: anti: type: diff --git a/ceph-osd/templates/daemonset-osd.yaml b/ceph-osd/templates/daemonset-osd.yaml index 88887b50c..617ca7fd9 100644 --- a/ceph-osd/templates/daemonset-osd.yaml +++ b/ceph-osd/templates/daemonset-osd.yaml @@ -34,6 +34,7 @@ spec: selector: matchLabels: {{ tuple $envAll "ceph" "osd" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 6 }} +{{ tuple $envAll "osd" | include "helm-toolkit.snippets.kubernetes_upgrades_daemonset" | indent 2 }} template: metadata: labels: diff --git a/ceph-osd/values.yaml b/ceph-osd/values.yaml index b617d9015..520c246e4 100644 --- a/ceph-osd/values.yaml +++ b/ceph-osd/values.yaml @@ -74,6 +74,14 @@ pod: allowPrivilegeEscalation: false readOnlyRootFilesystem: true dns_policy: "ClusterFirstWithHostNet" + lifecycle: + upgrades: + daemonsets: + pod_replacement_strategy: RollingUpdate + osd: + enabled: true + min_ready_seconds: 0 + max_unavailable: 1 affinity: anti: type: diff --git a/ceph-provisioners/templates/deployment-cephfs-provisioner.yaml b/ceph-provisioners/templates/deployment-cephfs-provisioner.yaml index 1566e1ad8..8021c501b 100644 --- a/ceph-provisioners/templates/deployment-cephfs-provisioner.yaml +++ b/ceph-provisioners/templates/deployment-cephfs-provisioner.yaml @@ -140,8 +140,7 @@ spec: selector: matchLabels: {{ tuple $envAll "cephfs" "provisioner" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 6 }} - strategy: - type: Recreate +{{ tuple $envAll | include "helm-toolkit.snippets.kubernetes_upgrades_deployment" | indent 2 }} template: metadata: labels: diff --git a/ceph-provisioners/templates/deployment-rbd-provisioner.yaml b/ceph-provisioners/templates/deployment-rbd-provisioner.yaml index f72769689..f74d9ba59 100644 --- a/ceph-provisioners/templates/deployment-rbd-provisioner.yaml +++ b/ceph-provisioners/templates/deployment-rbd-provisioner.yaml @@ -130,8 +130,7 @@ spec: selector: matchLabels: {{ tuple $envAll "rbd" "provisioner" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 6 }} - strategy: - type: Recreate +{{ tuple $envAll | include "helm-toolkit.snippets.kubernetes_upgrades_deployment" | indent 2 }} template: metadata: labels: diff --git a/ceph-provisioners/values.yaml b/ceph-provisioners/values.yaml index 7622bc6f7..783fbecff 100644 --- a/ceph-provisioners/values.yaml +++ b/ceph-provisioners/values.yaml @@ -105,6 +105,10 @@ pod: replicas: cephfs_provisioner: 2 rbd_provisioner: 2 + lifecycle: + upgrades: + deployments: + pod_replacement_strategy: Recreate affinity: anti: type: