diff --git a/charts/nutanix-csi-storage/Chart.yaml b/charts/nutanix-csi-storage/Chart.yaml index 269aee7..0af0347 100644 --- a/charts/nutanix-csi-storage/Chart.yaml +++ b/charts/nutanix-csi-storage/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v1 name: nutanix-csi-storage -version: 2.6.4 +version: 2.6.5 kubeVersion: ">= 1.17.0-0" description: Nutanix Container Storage Interface (CSI) Driver home: https://github.com/nutanix/helm diff --git a/charts/nutanix-csi-storage/templates/ntnx-csi-controller-deployment.yaml b/charts/nutanix-csi-storage/templates/ntnx-csi-controller-deployment.yaml index b10e39c..9b8a43e 100644 --- a/charts/nutanix-csi-storage/templates/ntnx-csi-controller-deployment.yaml +++ b/charts/nutanix-csi-storage/templates/ntnx-csi-controller-deployment.yaml @@ -35,7 +35,7 @@ spec: hostNetwork: true containers: - name: csi-provisioner - {{- if semverCompare ">=1.20-0" .Capabilities.KubeVersion.Version }} + {{- if semverCompare ">=1.20-0" .Capabilities.KubeVersion.Version }} image: {{ .Values.sidecars.provisioner.image }} {{- else }} image: {{ .Values.sidecars.provisioner.imageLegacy }} diff --git a/charts/nutanix-csi-storage/templates/ntnx-sc.yaml b/charts/nutanix-csi-storage/templates/ntnx-sc.yaml index 64f5804..7cd6678 100644 --- a/charts/nutanix-csi-storage/templates/ntnx-sc.yaml +++ b/charts/nutanix-csi-storage/templates/ntnx-sc.yaml @@ -5,27 +5,34 @@ kind: StorageClass apiVersion: storage.k8s.io/v1 metadata: - name: {{ .Values.volumeClassName }} -{{- if eq .Values.defaultStorageClass "volume" }} - annotations: - storageclass.kubernetes.io/is-default-class: "true" -{{- end }} + name: {{ .Values.volumeClassName }} + annotations: + {{- if eq .Values.defaultStorageClass "volume" }} + storageclass.kubernetes.io/is-default-class: "true" + {{- end }} + {{- with .Values.volumeClassAnnotations }} + {{ toYaml . | nindent 4 }} + {{- end }} + labels: + {{- with .Values.volumeClassLabels }} + {{ toYaml . | nindent 4 }} + {{- end }} provisioner: {{ include "nutanix-csi-storage.drivername" . }} parameters: - storageType: NutanixVolumes - csi.storage.k8s.io/provisioner-secret-name: {{ .Values.secretName }} - csi.storage.k8s.io/provisioner-secret-namespace: {{ .Release.Namespace }} - csi.storage.k8s.io/node-publish-secret-name: {{ .Values.secretName }} - csi.storage.k8s.io/node-publish-secret-namespace: {{ .Release.Namespace }} - csi.storage.k8s.io/controller-expand-secret-name: {{ .Values.secretName }} - csi.storage.k8s.io/controller-expand-secret-namespace: {{ .Release.Namespace }} - storageContainer: {{ .Values.storageContainer }} - csi.storage.k8s.io/fstype: {{ .Values.fsType }} - isSegmentedIscsiNetwork: {{ quote .Values.networkSegmentation }} - description: {{ quote (.Values.volumeClassDescription | default .Values.volumeClassName) }} + storageType: NutanixVolumes + csi.storage.k8s.io/provisioner-secret-name: {{ .Values.secretName }} + csi.storage.k8s.io/provisioner-secret-namespace: {{ .Release.Namespace }} + csi.storage.k8s.io/node-publish-secret-name: {{ .Values.secretName }} + csi.storage.k8s.io/node-publish-secret-namespace: {{ .Release.Namespace }} + csi.storage.k8s.io/controller-expand-secret-name: {{ .Values.secretName }} + csi.storage.k8s.io/controller-expand-secret-namespace: {{ .Release.Namespace }} + storageContainer: {{ .Values.storageContainer }} + csi.storage.k8s.io/fstype: {{ .Values.fsType }} + isSegmentedIscsiNetwork: {{ quote .Values.networkSegmentation }} + description: {{ quote (.Values.volumeClassDescription | default .Values.volumeClassName) }} {{- if eq .Values.lvmVolume true }} - isLVMVolume: "true" - numLVMDisks: {{ quote .Values.lvmDisks }} + isLVMVolume: "true" + numLVMDisks: {{ quote .Values.lvmDisks }} {{- end }} allowVolumeExpansion: true reclaimPolicy: {{ .Values.volumeClassRetention }} @@ -37,7 +44,15 @@ apiVersion: snapshot.storage.k8s.io/v1beta1 {{- end }} kind: VolumeSnapshotClass metadata: - name: nutanix-snapshot-class + name: {{ .Values.volumeSnapshotClassName }} + annotations: + {{- with .Values.volumeSnapshotClassAnnotations }} + {{ toYaml . | nindent 4 }} + {{- end }} + labels: + {{- with .Values.volumeSnapshotClassLabels }} + {{ toYaml . | nindent 4 }} + {{- end }} driver: {{ include "nutanix-csi-storage.drivername" . }} parameters: storageType: NutanixVolumes @@ -54,16 +69,23 @@ deletionPolicy: Delete kind: StorageClass apiVersion: storage.k8s.io/v1 metadata: - name: {{ .Values.fileClassName }} -{{- if eq .Values.defaultStorageClass "file" }} - annotations: - storageclass.kubernetes.io/is-default-class: "true" -{{- end }} + name: {{ .Values.fileClassName }} + annotations: + {{- if eq .Values.defaultStorageClass "file" }} + storageclass.kubernetes.io/is-default-class: "true" + {{- end }} + {{- with .Values.fileClassAnnotations }} + {{ toYaml . | nindent 4 }} + {{- end }} + labels: + {{- with .Values.fileClassLabels }} + {{ toYaml . | nindent 4 }} + {{- end }} provisioner: {{ include "nutanix-csi-storage.drivername" . }} parameters: - storageType: NutanixFiles - nfsServer: {{ .Values.fileHost }} - nfsPath: {{ .Values.filePath }} + storageType: NutanixFiles + nfsServer: {{ .Values.fileHost }} + nfsPath: {{ .Values.filePath }} reclaimPolicy: {{ .Values.fileClassRetention }} {{- end }} @@ -74,24 +96,31 @@ reclaimPolicy: {{ .Values.fileClassRetention }} kind: StorageClass apiVersion: storage.k8s.io/v1 metadata: - name: {{ .Values.dynamicFileClassName }} -{{- if eq .Values.defaultStorageClass "dynfile" }} - annotations: - storageclass.kubernetes.io/is-default-class: "true" -{{- end }} + name: {{ .Values.dynamicFileClassName }} + annotations: + {{- if eq .Values.defaultStorageClass "dynfile" }} + storageclass.kubernetes.io/is-default-class: "true" + {{- end }} + {{- with .Values.dynamicFileClassAnnotations }} + {{ toYaml . | nindent 4 }} + {{- end }} + labels: + {{- with .Values.dynamicFileClassLabels }} + {{ toYaml . | nindent 4 }} + {{- end }} provisioner: {{ include "nutanix-csi-storage.drivername" . }} parameters: - storageType: NutanixFiles - dynamicProv: ENABLED - squashType: {{ .Values.dynamicFileSquashType }} - nfsServerName: {{ .Values.fileServerName }} - csi.storage.k8s.io/provisioner-secret-name: {{ .Values.secretName }} - csi.storage.k8s.io/provisioner-secret-namespace: {{ .Release.Namespace }} - csi.storage.k8s.io/node-publish-secret-name: {{ .Values.secretName }} - csi.storage.k8s.io/node-publish-secret-namespace: {{ .Release.Namespace }} - csi.storage.k8s.io/controller-expand-secret-name: {{ .Values.secretName }} - csi.storage.k8s.io/controller-expand-secret-namespace: {{ .Release.Namespace }} - description: {{ quote (.Values.dynamicFileClassDescription | default .Values.dynamicFileClassName) }} + storageType: NutanixFiles + dynamicProv: ENABLED + squashType: {{ .Values.dynamicFileSquashType }} + nfsServerName: {{ .Values.fileServerName }} + csi.storage.k8s.io/provisioner-secret-name: {{ .Values.secretName }} + csi.storage.k8s.io/provisioner-secret-namespace: {{ .Release.Namespace }} + csi.storage.k8s.io/node-publish-secret-name: {{ .Values.secretName }} + csi.storage.k8s.io/node-publish-secret-namespace: {{ .Release.Namespace }} + csi.storage.k8s.io/controller-expand-secret-name: {{ .Values.secretName }} + csi.storage.k8s.io/controller-expand-secret-namespace: {{ .Release.Namespace }} + description: {{ quote (.Values.dynamicFileClassDescription | default .Values.dynamicFileClassName) }} allowVolumeExpansion: true reclaimPolicy: {{ .Values.dynamicFileClassRetention }} {{- end }} \ No newline at end of file diff --git a/charts/nutanix-csi-storage/values.yaml b/charts/nutanix-csi-storage/values.yaml index 737c6ef..8c951ac 100644 --- a/charts/nutanix-csi-storage/values.yaml +++ b/charts/nutanix-csi-storage/values.yaml @@ -34,15 +34,25 @@ volumeClass: false volumeClassName: "nutanix-volume" volumeClassRetention: "Delete" # volumeClassDescription: "" +# volumeClassAnnotations: {} +# volumeClassLabels: {} + +volumeSnapshotClassName: "nutanix-snapshot-class" +# volumeSnapshotClassAnnotations: {} +# volumeSnapshotClassLabels: {} fileClass: false fileClassName: "nutanix-file" fileClassRetention: "Delete" +# fileClassAnnotations: {} +# fileClassLabels: {} dynamicFileClass: false dynamicFileClassName: "nutanix-dynamicfile" dynamicFileClassRetention: "Delete" # dynamicFileClassDescription: "" +# dynamicFileClassAnnotations: {} +# dynamicFileClassLabels: {} # Default Storage Class settings #