Skip to content

Commit f49f22f

Browse files
authored
Merge pull request #1565 from nilekhc/nilekh/c/update-semvar-check
feat: handles sha string in tag
2 parents 91025bd + 18619d1 commit f49f22f

File tree

2 files changed

+8
-16
lines changed

2 files changed

+8
-16
lines changed

manifest_staging/charts/secrets-store-csi-driver/templates/secrets-store-csi-driver-windows.yaml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -74,17 +74,17 @@ spec:
7474
- "--nodeid=$(KUBE_NODE_NAME)"
7575
- "--provider-volume={{ .Values.windows.providersDir }}"
7676
- "--additional-provider-volume-paths={{ join "," .Values.windows.additionalProvidersDirs }}"
77-
{{- if and (semverCompare ">= v0.0.15-0" .Values.windows.image.tag) .Values.enableSecretRotation }}
77+
{{- if .Values.enableSecretRotation }}
7878
- "--enable-secret-rotation={{ .Values.enableSecretRotation }}"
7979
{{- end }}
80-
{{- if and (semverCompare ">= v0.0.15-0" .Values.windows.image.tag) .Values.rotationPollInterval }}
80+
{{- if .Values.rotationPollInterval }}
8181
- "--rotation-poll-interval={{ .Values.rotationPollInterval }}"
8282
{{- end }}
8383
- "--metrics-addr={{ .Values.windows.metricsAddr }}"
84-
{{- if and (semverCompare ">= v0.0.22-0" .Values.windows.image.tag) .Values.providerHealthCheck }}
84+
{{- if .Values.providerHealthCheck }}
8585
- "--provider-health-check={{ .Values.providerHealthCheck }}"
8686
{{- end }}
87-
{{- if and (semverCompare ">= v0.0.22-0" .Values.windows.image.tag) .Values.providerHealthCheckInterval }}
87+
{{- if .Values.providerHealthCheckInterval }}
8888
- "--provider-health-check-interval={{ .Values.providerHealthCheckInterval }}"
8989
{{- end }}
9090
{{- if .Values.maxCallRecvMsgSize }}
@@ -102,7 +102,6 @@ spec:
102102
apiVersion: v1
103103
fieldPath: spec.nodeName
104104
imagePullPolicy: {{ .Values.windows.image.pullPolicy }}
105-
{{- if semverCompare ">= v0.0.9-0" .Values.windows.image.tag }}
106105
ports:
107106
- containerPort: {{ .Values.livenessProbe.port }}
108107
name: healthz
@@ -118,7 +117,6 @@ spec:
118117
initialDelaySeconds: 30
119118
timeoutSeconds: 10
120119
periodSeconds: 15
121-
{{- end }}
122120
volumeMounts:
123121
- name: plugin-dir
124122
mountPath: C:\csi
@@ -140,7 +138,6 @@ spec:
140138
resources:
141139
{{ toYaml . | indent 12 }}
142140
{{- end }}
143-
{{- if semverCompare ">= v0.0.9-0" .Values.windows.image.tag }}
144141
- name: liveness-probe
145142
{{- if .Values.windows.livenessProbeImage.digest }}
146143
image: "{{ .Values.windows.livenessProbeImage.repository }}@{{ .Values.windows.livenessProbeImage.digest }}"
@@ -160,7 +157,6 @@ spec:
160157
resources:
161158
{{ toYaml . | indent 12 }}
162159
{{- end }}
163-
{{- end }}
164160
{{- if .Values.windows.priorityClassName }}
165161
priorityClassName: {{ .Values.windows.priorityClassName | quote }}
166162
{{- end }}

manifest_staging/charts/secrets-store-csi-driver/templates/secrets-store-csi-driver.yaml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -74,17 +74,17 @@ spec:
7474
- "--nodeid=$(KUBE_NODE_NAME)"
7575
- "--provider-volume={{ .Values.linux.providersDir }}"
7676
- "--additional-provider-volume-paths={{ join "," .Values.linux.additionalProvidersDirs }}"
77-
{{- if and (semverCompare ">= v0.0.15-0" .Values.linux.image.tag) .Values.enableSecretRotation }}
77+
{{- if .Values.enableSecretRotation }}
7878
- "--enable-secret-rotation={{ .Values.enableSecretRotation }}"
7979
{{- end }}
80-
{{- if and (semverCompare ">= v0.0.15-0" .Values.linux.image.tag) .Values.rotationPollInterval }}
80+
{{- if .Values.rotationPollInterval }}
8181
- "--rotation-poll-interval={{ .Values.rotationPollInterval }}"
8282
{{- end }}
8383
- "--metrics-addr={{ .Values.linux.metricsAddr }}"
84-
{{- if and (semverCompare ">= v0.0.22-0" .Values.linux.image.tag) .Values.providerHealthCheck }}
84+
{{- if .Values.providerHealthCheck }}
8585
- "--provider-health-check={{ .Values.providerHealthCheck }}"
8686
{{- end }}
87-
{{- if and (semverCompare ">= v0.0.22-0" .Values.linux.image.tag) .Values.providerHealthCheckInterval }}
87+
{{- if .Values.providerHealthCheckInterval }}
8888
- "--provider-health-check-interval={{ .Values.providerHealthCheckInterval }}"
8989
{{- end }}
9090
{{- if .Values.maxCallRecvMsgSize }}
@@ -104,7 +104,6 @@ spec:
104104
imagePullPolicy: {{ .Values.linux.image.pullPolicy }}
105105
securityContext:
106106
privileged: true
107-
{{- if semverCompare ">= v0.0.8-0" .Values.linux.image.tag }}
108107
ports:
109108
- containerPort: {{ .Values.livenessProbe.port }}
110109
name: healthz
@@ -120,7 +119,6 @@ spec:
120119
initialDelaySeconds: 30
121120
timeoutSeconds: 10
122121
periodSeconds: 15
123-
{{- end }}
124122
volumeMounts:
125123
- name: plugin-dir
126124
mountPath: /csi
@@ -143,7 +141,6 @@ spec:
143141
resources:
144142
{{ toYaml . | indent 12 }}
145143
{{- end }}
146-
{{- if semverCompare ">= v0.0.8-0" .Values.linux.image.tag }}
147144
- name: liveness-probe
148145
{{- if .Values.linux.livenessProbeImage.digest }}
149146
image: "{{ .Values.linux.livenessProbeImage.repository }}@{{ .Values.linux.livenessProbeImage.digest }}"
@@ -163,7 +160,6 @@ spec:
163160
resources:
164161
{{ toYaml . | indent 12 }}
165162
{{- end }}
166-
{{- end }}
167163
{{- if .Values.linux.priorityClassName }}
168164
priorityClassName: {{ .Values.linux.priorityClassName | quote }}
169165
{{- end }}

0 commit comments

Comments
 (0)