From 9704d042c4eb53d3b9ba858b6bdc63bad45c2b57 Mon Sep 17 00:00:00 2001 From: "martin.kucin" Date: Tue, 9 Apr 2024 14:57:19 +0200 Subject: [PATCH] feat(deployment/daemonset): Remove imagePullPolicy from charts --- .../templates/controller/deployment.yaml | 9 +++++++-- .../rancher-vsphere-csi/templates/node/daemonset.yaml | 4 +++- charts/rancher-vsphere-csi/values.yaml | 10 ++++++++++ 3 files changed, 20 insertions(+), 3 deletions(-) diff --git a/charts/rancher-vsphere-csi/templates/controller/deployment.yaml b/charts/rancher-vsphere-csi/templates/controller/deployment.yaml index 99d39ac..fd91e02 100644 --- a/charts/rancher-vsphere-csi/templates/controller/deployment.yaml +++ b/charts/rancher-vsphere-csi/templates/controller/deployment.yaml @@ -85,6 +85,7 @@ spec: containers: - name: csi-attacher image: "{{ template "system_default_registry" . }}{{ .Values.csiController.image.csiAttacher.repository }}:{{ .Values.csiController.image.csiAttacher.tag }}" + imagePullPolicy: {{ .Values.csiController.image.csiAttacher.imagePullPolicy | quote }} args: - "--v=4" - "--timeout=300s" @@ -101,6 +102,7 @@ spec: {{- if .Values.csiController.csiResizer.enabled }} - name: csi-resizer image: "{{ template "system_default_registry" . }}{{ .Values.csiController.image.csiResizer.repository }}:{{ .Values.csiController.image.csiResizer.tag }}" + imagePullPolicy: {{ .Values.csiController.image.csiResizer.imagePullPolicy | quote }} args: - "--v=4" - "--timeout=300s" @@ -119,6 +121,7 @@ spec: {{- if .Values.blockVolumeSnapshot.enabled }} - name: csi-snapshotter image: "{{ template "system_default_registry" . }}{{ .Values.csiController.image.csiSnapshotter.repository }}:{{ .Values.csiController.image.csiSnapshotter.tag }}" + imagePullPolicy: {{ .Values.csiController.image.csiSnapshotter.imagePullPolicy | quote }} args: - "--v=4" - "--kube-api-qps=100" @@ -138,13 +141,13 @@ spec: {{- end }} - name: vsphere-csi-controller image: "{{ template "system_default_registry" . }}{{ .Values.csiController.image.repository }}:{{ .Values.csiController.image.tag }}" + imagePullPolicy: {{ .Values.csiController.image.imagePullPolicy | quote }} args: - "--fss-name=internal-feature-states.csi.vsphere.vmware.com" - "--fss-namespace=$(CSI_NAMESPACE)" {{- if semverCompare "< 1.24" $.Capabilities.KubeVersion.Version }} - "--use-gocsi=false" {{- end }} - imagePullPolicy: "Always" env: - name: CSI_ENDPOINT value: unix:///csi/csi.sock @@ -189,6 +192,7 @@ spec: failureThreshold: 3 - name: liveness-probe image: "{{ template "system_default_registry" . }}{{ .Values.csiController.image.livenessProbe.repository }}:{{ .Values.csiController.image.livenessProbe.tag }}" + imagePullPolicy: {{ .Values.csiController.image.livenessProbe.imagePullPolicy | quote }} args: - "--v=4" - "--csi-address=/csi/csi.sock" @@ -197,11 +201,11 @@ spec: mountPath: /csi - name: vsphere-syncer image: "{{ template "system_default_registry" . }}{{ .Values.csiController.image.vsphereSyncer.repository }}:{{ .Values.csiController.image.vsphereSyncer.tag }}" + imagePullPolicy: {{ .Values.csiController.image.vsphereSyncer.imagePullPolicy | quote }} args: - "--leader-election" - "--fss-name=internal-feature-states.csi.vsphere.vmware.com" - "--fss-namespace=$(CSI_NAMESPACE)" - imagePullPolicy: "Always" ports: - containerPort: 2113 name: prometheus @@ -227,6 +231,7 @@ spec: readOnly: true - name: csi-provisioner image: "{{ template "system_default_registry" . }}{{ .Values.csiController.image.csiProvisioner.repository }}:{{ .Values.csiController.image.csiProvisioner.tag }}" + imagePullPolicy: {{ .Values.csiController.image.csiProvisioner.imagePullPolicy | quote }} args: - "--v=4" - "--timeout=300s" diff --git a/charts/rancher-vsphere-csi/templates/node/daemonset.yaml b/charts/rancher-vsphere-csi/templates/node/daemonset.yaml index 892e44f..864d57a 100644 --- a/charts/rancher-vsphere-csi/templates/node/daemonset.yaml +++ b/charts/rancher-vsphere-csi/templates/node/daemonset.yaml @@ -68,6 +68,7 @@ spec: containers: - name: node-driver-registrar image: "{{ template "system_default_registry" . }}{{ .Values.csiNode.image.nodeDriverRegistrar.repository }}:{{ .Values.csiNode.image.nodeDriverRegistrar.tag }}" + imagePullPolicy: {{ .Values.csiNode.image.nodeDriverRegistrar.imagePullPolicy | quote }} args: - "--v=5" - "--csi-address=$(ADDRESS)" @@ -91,13 +92,13 @@ spec: initialDelaySeconds: 3 - name: vsphere-csi-node image: "{{ template "system_default_registry" . }}{{ .Values.csiNode.image.repository }}:{{ .Values.csiNode.image.tag }}" + imagePullPolicy: {{ .Values.csiNode.image.imagePullPolicy | quote }} args: - "--fss-name=internal-feature-states.csi.vsphere.vmware.com" - "--fss-namespace=$(CSI_NAMESPACE)" {{- if semverCompare "< 1.24" $.Capabilities.KubeVersion.Version }} - "--use-gocsi=false" {{- end }} - imagePullPolicy: "Always" env: - name: NODE_NAME valueFrom: @@ -154,6 +155,7 @@ spec: failureThreshold: 3 - name: liveness-probe image: "{{ template "system_default_registry" . }}{{ .Values.csiNode.image.livenessProbe.repository }}:{{ .Values.csiNode.image.livenessProbe.tag }}" + imagePullPolicy: {{ .Values.csiNode.image.livenessProbe.imagePullPolicy | quote }} args: - "--v=4" - "--csi-address=/csi/csi.sock" diff --git a/charts/rancher-vsphere-csi/values.yaml b/charts/rancher-vsphere-csi/values.yaml index a27ca2e..2ff1043 100644 --- a/charts/rancher-vsphere-csi/values.yaml +++ b/charts/rancher-vsphere-csi/values.yaml @@ -26,24 +26,31 @@ csiController: image: repository: rancher/mirrored-cloud-provider-vsphere-csi-release-driver tag: latest + imagePullPolicy: "" csiAttacher: repository: rancher/mirrored-sig-storage-csi-attacher tag: latest + imagePullPolicy: "" csiResizer: repository: rancher/mirrored-sig-storage-csi-resizer tag: latest + imagePullPolicy: "" livenessProbe: repository: rancher/mirrored-sig-storage-livenessprobe tag: latest + imagePullPolicy: "" vsphereSyncer: repository: rancher/mirrored-cloud-provider-vsphere-csi-release-syncer tag: latest + imagePullPolicy: "" csiProvisioner: repository: rancher/mirrored-sig-storage-csi-provisioner tag: latest + imagePullPolicy: "" csiSnapshotter: repository: rancher/mirrored-sig-storage-csi-snapshotter tag: latest + imagePullPolicy: "" ## Node labels for pod assignment ## Ref: https://kubernetes.io/docs/user-guide/node-selection/ ## @@ -113,12 +120,15 @@ csiNode: image: repository: rancher/mirrored-cloud-provider-vsphere-csi-release-driver tag: latest + imagePullPolicy: "" nodeDriverRegistrar: repository: rancher/mirrored-sig-storage-csi-node-driver-registrar tag: latest + imagePullPolicy: "" livenessProbe: repository: rancher/mirrored-sig-storage-livenessprobe tag: latest + imagePullPolicy: "" storageClass: enabled: true