From 4d28a981fcd7d9f6c30689eee6731b099da6ab95 Mon Sep 17 00:00:00 2001 From: Madhu Rajanna Date: Thu, 2 Jan 2020 14:18:30 +0530 Subject: [PATCH] Remove hard-coded UpdateStrategy from templates Provided an option to specify the UpdateStrategy in helm charts. Signed-off-by: Madhu Rajanna --- charts/ceph-csi-cephfs/templates/nodeplugin-daemonset.yaml | 2 ++ charts/ceph-csi-cephfs/values.yaml | 2 ++ charts/ceph-csi-rbd/templates/nodeplugin-daemonset.yaml | 2 +- charts/ceph-csi-rbd/values.yaml | 2 ++ deploy/rbd/kubernetes/v1.13/csi-rbdplugin.yaml | 2 -- deploy/rbd/kubernetes/v1.14+/csi-rbdplugin.yaml | 2 -- 6 files changed, 7 insertions(+), 5 deletions(-) diff --git a/charts/ceph-csi-cephfs/templates/nodeplugin-daemonset.yaml b/charts/ceph-csi-cephfs/templates/nodeplugin-daemonset.yaml index 72adeebd9..c5d336af2 100644 --- a/charts/ceph-csi-cephfs/templates/nodeplugin-daemonset.yaml +++ b/charts/ceph-csi-cephfs/templates/nodeplugin-daemonset.yaml @@ -15,6 +15,8 @@ spec: app: {{ include "ceph-csi-cephfs.name" . }} component: {{ .Values.nodeplugin.name }} release: {{ .Release.Name }} + updateStrategy: + type: {{ .Values.nodeplugin.updateStrategy }} template: metadata: labels: diff --git a/charts/ceph-csi-cephfs/values.yaml b/charts/ceph-csi-cephfs/values.yaml index 47fab9581..b58099da6 100644 --- a/charts/ceph-csi-cephfs/values.yaml +++ b/charts/ceph-csi-cephfs/values.yaml @@ -29,6 +29,8 @@ csiConfig: [] nodeplugin: name: nodeplugin + # if you are using ceph-fuse client set this value to OnDelete + updateStrategy: RollingUpdate httpMetrics: # Metrics only available for cephcis/cephsi => 1.2.0 diff --git a/charts/ceph-csi-rbd/templates/nodeplugin-daemonset.yaml b/charts/ceph-csi-rbd/templates/nodeplugin-daemonset.yaml index 3c03d4541..21b309891 100644 --- a/charts/ceph-csi-rbd/templates/nodeplugin-daemonset.yaml +++ b/charts/ceph-csi-rbd/templates/nodeplugin-daemonset.yaml @@ -16,7 +16,7 @@ spec: component: {{ .Values.nodeplugin.name }} release: {{ .Release.Name }} updateStrategy: - type: OnDelete + type: {{ .Values.nodeplugin.updateStrategy }} template: metadata: labels: diff --git a/charts/ceph-csi-rbd/values.yaml b/charts/ceph-csi-rbd/values.yaml index 1736f41f7..b6fe02a69 100644 --- a/charts/ceph-csi-rbd/values.yaml +++ b/charts/ceph-csi-rbd/values.yaml @@ -29,6 +29,8 @@ csiConfig: [] nodeplugin: name: nodeplugin + # if you are using rbd-nbd client set this value to OnDelete + updateStrategy: RollingUpdate httpMetrics: # Metrics only available for cephcsi/cephcsi => 1.2.0 diff --git a/deploy/rbd/kubernetes/v1.13/csi-rbdplugin.yaml b/deploy/rbd/kubernetes/v1.13/csi-rbdplugin.yaml index 3d1740eb2..63fca5db0 100644 --- a/deploy/rbd/kubernetes/v1.13/csi-rbdplugin.yaml +++ b/deploy/rbd/kubernetes/v1.13/csi-rbdplugin.yaml @@ -7,8 +7,6 @@ spec: selector: matchLabels: app: csi-rbdplugin - updateStrategy: - type: OnDelete template: metadata: labels: diff --git a/deploy/rbd/kubernetes/v1.14+/csi-rbdplugin.yaml b/deploy/rbd/kubernetes/v1.14+/csi-rbdplugin.yaml index ef7a544d4..73c22ba18 100644 --- a/deploy/rbd/kubernetes/v1.14+/csi-rbdplugin.yaml +++ b/deploy/rbd/kubernetes/v1.14+/csi-rbdplugin.yaml @@ -7,8 +7,6 @@ spec: selector: matchLabels: app: csi-rbdplugin - updateStrategy: - type: OnDelete template: metadata: labels: