From 518ccf42b34e4351084d9f18fbe72f7b36fa5d7f Mon Sep 17 00:00:00 2001 From: Madhu Rajanna Date: Tue, 8 Dec 2020 16:19:39 +0530 Subject: [PATCH] deploy: add option to set default-fstype in provisioner external-provisioner is exposing a new argument to set the default fstype while starting the provisioner sidecar, if the fstype is not specified in the storageclass the default fstype will be applied for the pvc created from the storageclass. Signed-off-by: Madhu Rajanna --- charts/ceph-csi-rbd/templates/provisioner-deployment.yaml | 1 + charts/ceph-csi-rbd/values.yaml | 2 ++ deploy/rbd/kubernetes/csi-rbdplugin-provisioner.yaml | 2 ++ 3 files changed, 5 insertions(+) diff --git a/charts/ceph-csi-rbd/templates/provisioner-deployment.yaml b/charts/ceph-csi-rbd/templates/provisioner-deployment.yaml index 885db29b3..191500d5b 100644 --- a/charts/ceph-csi-rbd/templates/provisioner-deployment.yaml +++ b/charts/ceph-csi-rbd/templates/provisioner-deployment.yaml @@ -52,6 +52,7 @@ spec: - "--timeout={{ .Values.provisioner.timeout }}" - "--leader-election=true" - "--retry-interval-start=500ms" + - "--default-fstype={{ .Values.provisioner.defaultFSType }}" {{- if .Values.topology.enabled }} - "--feature-gates=Topology=true" {{- end }} diff --git a/charts/ceph-csi-rbd/values.yaml b/charts/ceph-csi-rbd/values.yaml index 907b77fc3..6125f38ed 100644 --- a/charts/ceph-csi-rbd/values.yaml +++ b/charts/ceph-csi-rbd/values.yaml @@ -110,6 +110,8 @@ nodeplugin: provisioner: name: provisioner replicaCount: 3 + # if fstype is not specified in storageclass, ext4 is default + defaultFSType: ext4 # deployController to enable or disable the deployment of controller which # generates the OMAP data if its not Present. deployController: true diff --git a/deploy/rbd/kubernetes/csi-rbdplugin-provisioner.yaml b/deploy/rbd/kubernetes/csi-rbdplugin-provisioner.yaml index 103bf92f7..cd223bbaf 100644 --- a/deploy/rbd/kubernetes/csi-rbdplugin-provisioner.yaml +++ b/deploy/rbd/kubernetes/csi-rbdplugin-provisioner.yaml @@ -51,6 +51,8 @@ spec: - "--leader-election=true" # set it to true to use topology based provisioning - "--feature-gates=Topology=false" + # if fstype is not specified in storageclass, ext4 is default + - "--default-fstype=ext4" env: - name: ADDRESS value: unix:///csi/csi-provisioner.sock