From 0e6443e4c173f2e3e5d28502c97472ca166f7556 Mon Sep 17 00:00:00 2001 From: Niels de Vos Date: Thu, 22 Oct 2020 10:37:05 +0530 Subject: [PATCH] deploy: add --extra-create-metadata arg to csi-provisioner sidecar This argument in csi-provisioner sidecar allows us to receive pv/pvc name/namespace metadata in the createVolume() request. For ex: csi.storage.k8s.io/pvc/name csi.storage.k8s.io/pvc/namespace csi.storage.k8s.io/pv/name This is a useful information which can be used depend on the use case we have at our driver. The features like vault token enablement for multi tenancy, RBD mirroring ..etc can consume this based on the need. Refer: #1305 Signed-off-by: Humble Chirammal Signed-off-by: Niels de Vos --- charts/ceph-csi-cephfs/templates/provisioner-deployment.yaml | 1 + charts/ceph-csi-rbd/templates/provisioner-deployment.yaml | 1 + deploy/cephfs/kubernetes/csi-cephfsplugin-provisioner.yaml | 1 + deploy/rbd/kubernetes/csi-rbdplugin-provisioner.yaml | 1 + 4 files changed, 4 insertions(+) diff --git a/charts/ceph-csi-cephfs/templates/provisioner-deployment.yaml b/charts/ceph-csi-cephfs/templates/provisioner-deployment.yaml index 2236ec3b2..dbf14b7d7 100644 --- a/charts/ceph-csi-cephfs/templates/provisioner-deployment.yaml +++ b/charts/ceph-csi-cephfs/templates/provisioner-deployment.yaml @@ -52,6 +52,7 @@ spec: - "--timeout={{ .Values.provisioner.timeout }}" - "--leader-election=true" - "--retry-interval-start=500ms" + - "--extra-create-metadata=true" {{- if .Values.topology.enabled }} - "--feature-gates=Topology=true" {{- end }} diff --git a/charts/ceph-csi-rbd/templates/provisioner-deployment.yaml b/charts/ceph-csi-rbd/templates/provisioner-deployment.yaml index 191500d5b..0efab99fa 100644 --- a/charts/ceph-csi-rbd/templates/provisioner-deployment.yaml +++ b/charts/ceph-csi-rbd/templates/provisioner-deployment.yaml @@ -53,6 +53,7 @@ spec: - "--leader-election=true" - "--retry-interval-start=500ms" - "--default-fstype={{ .Values.provisioner.defaultFSType }}" + - "--extra-create-metadata=true" {{- if .Values.topology.enabled }} - "--feature-gates=Topology=true" {{- end }} diff --git a/deploy/cephfs/kubernetes/csi-cephfsplugin-provisioner.yaml b/deploy/cephfs/kubernetes/csi-cephfsplugin-provisioner.yaml index a109c0535..4e6e21f34 100644 --- a/deploy/cephfs/kubernetes/csi-cephfsplugin-provisioner.yaml +++ b/deploy/cephfs/kubernetes/csi-cephfsplugin-provisioner.yaml @@ -50,6 +50,7 @@ spec: - "--leader-election=true" - "--retry-interval-start=500ms" - "--feature-gates=Topology=false" + - "--extra-create-metadata=true" env: - name: ADDRESS value: unix:///csi/csi-provisioner.sock diff --git a/deploy/rbd/kubernetes/csi-rbdplugin-provisioner.yaml b/deploy/rbd/kubernetes/csi-rbdplugin-provisioner.yaml index cd223bbaf..09c288e45 100644 --- a/deploy/rbd/kubernetes/csi-rbdplugin-provisioner.yaml +++ b/deploy/rbd/kubernetes/csi-rbdplugin-provisioner.yaml @@ -53,6 +53,7 @@ spec: - "--feature-gates=Topology=false" # if fstype is not specified in storageclass, ext4 is default - "--default-fstype=ext4" + - "--extra-create-metadata=true" env: - name: ADDRESS value: unix:///csi/csi-provisioner.sock