2020-12-16 11:22:56 +00:00
|
|
|
{{- if .Values.storageClass.create -}}
|
|
|
|
apiVersion: storage.k8s.io/v1
|
|
|
|
kind: StorageClass
|
|
|
|
metadata:
|
2021-10-26 03:32:17 +00:00
|
|
|
name: {{ .Values.storageClass.name }}
|
|
|
|
{{- if .Values.storageClass.annotations }}
|
|
|
|
annotations:
|
|
|
|
{{ toYaml .Values.storageClass.annotations | indent 4 }}
|
|
|
|
{{- end }}
|
|
|
|
labels:
|
|
|
|
app: {{ include "ceph-csi-rbd.name" . }}
|
|
|
|
chart: {{ include "ceph-csi-rbd.chart" . }}
|
|
|
|
release: {{ .Release.Name }}
|
|
|
|
heritage: {{ .Release.Service }}
|
2022-10-14 14:59:09 +00:00
|
|
|
{{- with .Values.commonLabels }}{{ toYaml . | trim | nindent 4 }}{{- end }}
|
2020-12-16 11:22:56 +00:00
|
|
|
provisioner: {{ .Values.driverName }}
|
|
|
|
parameters:
|
|
|
|
clusterID: {{ .Values.storageClass.clusterID }}
|
|
|
|
imageFeatures: {{ .Values.storageClass.imageFeatures }}
|
2024-02-26 13:59:58 +00:00
|
|
|
{{- if .Values.storageClass.pool }}
|
|
|
|
pool: {{ .Values.storageClass.pool }}
|
|
|
|
{{- end }}
|
2021-10-05 10:47:11 +00:00
|
|
|
{{- if .Values.storageClass.tryOtherMounters }}
|
|
|
|
tryOtherMounters: {{ .Values.storageClass.tryOtherMounters | quote}}
|
|
|
|
{{- end }}
|
2023-11-06 18:03:12 +00:00
|
|
|
{{- if .Values.storageClass.mkfsOptions }}
|
|
|
|
mkfsOptions: {{ .Values.storageClass.mkfsOptions }}
|
|
|
|
{{- end }}
|
2020-12-16 11:22:56 +00:00
|
|
|
{{- if .Values.storageClass.mounter }}
|
|
|
|
mounter: {{ .Values.storageClass.mounter }}
|
|
|
|
{{- end }}
|
2021-09-01 12:24:42 +00:00
|
|
|
{{- if .Values.storageClass.cephLogDir }}
|
|
|
|
cephLogDir: {{ .Values.storageClass.cephLogDir }}
|
|
|
|
{{- end }}
|
2021-09-01 11:53:43 +00:00
|
|
|
{{- if .Values.storageClass.cephLogStrategy }}
|
|
|
|
cephLogStrategy: {{ .Values.storageClass.cephLogStrategy }}
|
|
|
|
{{- end }}
|
2020-12-16 11:22:56 +00:00
|
|
|
{{- if .Values.storageClass.dataPool }}
|
|
|
|
dataPool: {{ .Values.storageClass.dataPool }}
|
|
|
|
{{- end }}
|
|
|
|
{{- if .Values.storageClass.volumeNamePrefix }}
|
|
|
|
volumeNamePrefix: "{{ .Values.storageClass.volumeNamePrefix }}"
|
|
|
|
{{- end }}
|
|
|
|
{{- if .Values.storageClass.encrypted }}
|
|
|
|
encrypted: "{{ .Values.storageClass.encrypted }}"
|
|
|
|
{{- end }}
|
|
|
|
{{- if .Values.storageClass.encryptionKMSID }}
|
|
|
|
encryptionKMSID: {{ .Values.storageClass.encryptionKMSID }}
|
|
|
|
{{- end }}
|
|
|
|
{{- if .Values.storageClass.topologyConstrainedPools }}
|
|
|
|
topologyConstrainedPools:
|
|
|
|
{{ toYaml .Values.storageClass.topologyConstrainedPools | indent 4 -}}
|
|
|
|
{{- end }}
|
|
|
|
{{- if .Values.storageClass.mapOptions }}
|
|
|
|
mapOptions: {{ .Values.storageClass.mapOptions }}
|
|
|
|
{{- end }}
|
|
|
|
{{- if .Values.storageClass.unmapOptions }}
|
|
|
|
unmapOptions: {{ .Values.storageClass.unmapOptions }}
|
2023-11-05 15:24:19 +00:00
|
|
|
{{- end }}
|
|
|
|
{{- if .Values.storageClass.stripeUnit }}
|
|
|
|
stripeUnit: {{ .Values.storageClass.stripeUnit | quote }}
|
|
|
|
{{- end }}
|
|
|
|
{{- if .Values.storageClass.stripeCount }}
|
|
|
|
stripeCount: {{ .Values.storageClass.stripeCount | quote }}
|
|
|
|
{{- end }}
|
|
|
|
{{- if .Values.storageClass.objectSize }}
|
|
|
|
objectSize: {{ .Values.storageClass.objectSize | quote }}
|
2020-12-16 11:22:56 +00:00
|
|
|
{{- end }}
|
|
|
|
csi.storage.k8s.io/provisioner-secret-name: {{ .Values.storageClass.provisionerSecret }}
|
|
|
|
{{- if .Values.storageClass.provisionerSecretNamespace }}
|
|
|
|
csi.storage.k8s.io/provisioner-secret-namespace: {{ .Values.storageClass.provisionerSecretNamespace }}
|
|
|
|
{{ else }}
|
|
|
|
csi.storage.k8s.io/provisioner-secret-namespace: {{ .Release.Namespace }}
|
|
|
|
{{- end }}
|
|
|
|
csi.storage.k8s.io/controller-expand-secret-name: {{ .Values.storageClass.controllerExpandSecret }}
|
|
|
|
{{- if .Values.storageClass.controllerExpandSecretNamespace }}
|
|
|
|
csi.storage.k8s.io/controller-expand-secret-namespace: {{ .Values.storageClass.controllerExpandSecretNamespace }}
|
|
|
|
{{ else }}
|
|
|
|
csi.storage.k8s.io/controller-expand-secret-namespace: {{ .Release.Namespace }}
|
|
|
|
{{- end }}
|
|
|
|
csi.storage.k8s.io/node-stage-secret-name: {{ .Values.storageClass.nodeStageSecret }}
|
|
|
|
{{- if .Values.storageClass.nodeStageSecretNamespace }}
|
|
|
|
csi.storage.k8s.io/node-stage-secret-namespace: {{ .Values.storageClass.nodeStageSecretNamespace }}
|
|
|
|
{{ else }}
|
|
|
|
csi.storage.k8s.io/node-stage-secret-namespace: {{ .Release.Namespace }}
|
|
|
|
{{- end }}
|
|
|
|
csi.storage.k8s.io/fstype: {{ .Values.storageClass.fstype }}
|
|
|
|
reclaimPolicy: {{ .Values.storageClass.reclaimPolicy }}
|
|
|
|
allowVolumeExpansion: {{ .Values.storageClass.allowVolumeExpansion }}
|
|
|
|
{{- if .Values.storageClass.mountOptions }}
|
|
|
|
mountOptions:
|
|
|
|
{{- range .Values.storageClass.mountOptions }}
|
|
|
|
- {{ . }}
|
|
|
|
{{- end }}
|
|
|
|
{{- end }}
|
|
|
|
{{- end -}}
|