| diff --git a/cinder/templates/configmap-etc.yaml b/cinder/templates/configmap-etc.yaml |
| index 1a20ea84..97bfe0f7 100644 |
| --- a/cinder/templates/configmap-etc.yaml |
| +++ b/cinder/templates/configmap-etc.yaml |
| @@ -165,6 +165,14 @@ limitations under the License. |
| {{- $formatter_fluent := dict "class" "oslo_log.formatters.FluentFormatter" -}} |
| {{- $_ := set .Values.conf.logging "formatter_fluent" $formatter_fluent -}} |
| {{- end -}} |
| + |
| +{{- range $key, $backend := .Values.conf.backends }} |
| +{{- if and $backend.nfs_shares_config (not $backend.nfs_shares_config_content) }} |
| +{{- $nfs_shares_config_content := $backend.nfs_shares_config }} |
| +{{- $_ := set $backend "nfs_shares_config_content" $nfs_shares_config_content -}} |
| +{{- $_ := set $backend "nfs_shares_config" (printf "/etc/cinder/nfs/%s" $key) -}} |
| +{{- end -}} |
| +{{- end -}} |
| --- |
| apiVersion: v1 |
| kind: Secret |
| @@ -198,3 +206,13 @@ data: |
| external-ceph.conf: {{ include "helm-toolkit.utils.to_oslo_conf" .Values.ceph_client.external_ceph.conf | b64enc }} |
| {{- end }} |
| {{- end }} |
| +{{- range $key, $backend := .Values.conf.backends }} |
| +{{- if $backend.nfs_shares_config }} |
| + nfs-{{ $key }}: | |
| + {{- if kindIs "string" $backend.nfs_shares_config_content }} |
| + {{ $backend.nfs_shares_config_content | b64enc }} |
| + {{- else if kindIs "slice" $backend.nfs_shares_config_content }} |
| + {{ $backend.nfs_shares_config_content | join "\n" | b64enc }} |
| + {{- end }} |
| +{{- end }} |
| +{{- end }} |
| diff --git a/cinder/templates/deployment-volume.yaml b/cinder/templates/deployment-volume.yaml |
| index 93625536..a21c13ef 100644 |
| --- a/cinder/templates/deployment-volume.yaml |
| +++ b/cinder/templates/deployment-volume.yaml |
| @@ -242,6 +242,14 @@ spec: |
| readOnly: true |
| {{- end }} |
| {{- end }} |
| + {{- range $key, $backend := .Values.conf.backends }} |
| + {{- if $backend.nfs_shares_config }} |
| + - name: cinder-etc |
| + mountPath: /etc/cinder/nfs/{{ $key }} |
| + subPath: nfs-{{ $key }} |
| + readOnly: true |
| + {{- end }} |
| + {{- end }} |
| {{- if .Values.conf.enable_iscsi }} |
| - name: host-rootfs |
| mountPath: /mnt/host-rootfs |