Skip to content

Commit 20f77ec

Browse files
authored
Merge pull request #998 from kubernetes-csi/copilot/add-csidriver-labels-support
feat: Add driver.labels option to helm chart for CSIDriver resource
2 parents 6d87abf + f338d12 commit 20f77ec

File tree

4 files changed

+6
-1
lines changed

4 files changed

+6
-1
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ BUILD_DATE := $(shell date -u +"%Y-%m-%dT%H:%M:%SZ")
4444
endif
4545
LDFLAGS = -X ${PKG}/pkg/smb.driverVersion=${IMAGE_VERSION} -X ${PKG}/pkg/smb.gitCommit=${GIT_COMMIT} -X ${PKG}/pkg/smb.buildDate=${BUILD_DATE}
4646
EXT_LDFLAGS = -s -w -extldflags "-static"
47-
E2E_HELM_OPTIONS ?= --set image.smb.repository=$(REGISTRY)/$(IMAGENAME) --set image.smb.tag=$(IMAGE_VERSION) --set controller.runOnControlPlane=true
47+
E2E_HELM_OPTIONS ?= --set image.smb.repository=$(REGISTRY)/$(IMAGENAME) --set image.smb.tag=$(IMAGE_VERSION) --set controller.runOnControlPlane=true --set driver.labels.testlabel=testvalue
4848
E2E_HELM_OPTIONS += ${EXTRA_HELM_OPTIONS}
4949
# Generate all combination of all OS, ARCH, and OSVERSIONS for iteration
5050
ALL_OS = linux windows
23 Bytes
Binary file not shown.

charts/latest/csi-driver-smb/templates/csi-smb-driver.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ apiVersion: storage.k8s.io/v1
33
kind: CSIDriver
44
metadata:
55
name: {{ .Values.driver.name }}
6+
{{- if .Values.driver.labels }}
7+
labels:
8+
{{- toYaml .Values.driver.labels | nindent 4 }}
9+
{{- end }}
610
spec:
711
attachRequired: false
812
podInfoOnMount: true

charts/latest/csi-driver-smb/values.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ rbac:
3636

3737
driver:
3838
name: smb.csi.k8s.io
39+
labels: {}
3940

4041
feature:
4142
enableGetVolumeStats: true

0 commit comments

Comments
 (0)