Cinder: Enable iscsi to work correctly in cinder volume

This PS enables iscsi actions to work correctly in cinder
volume - enabling things like conversion of glance images
to cinder volumes (required for nova-boot-from-volume)

Change-Id: I63521ff9609ad89485a843bc0fbddb00e38dccc8
Signed-off-by: Pete Birley <pete@port.direct>
This commit is contained in:
intlabs 2021-01-06 11:51:05 -06:00 committed by Pete Birley
parent cdabba7e21
commit 97187997e4
2 changed files with 15 additions and 1 deletions

@ -14,7 +14,7 @@ apiVersion: v1
appVersion: v1.0.0
description: OpenStack-Helm Cinder
name: cinder
version: 0.1.3
version: 0.1.4
home: https://docs.openstack.org/cinder/latest/
icon: https://www.openstack.org/themes/openstack/images/project-mascots/Cinder/OpenStack_Project_Cinder_vertical.png
sources:

@ -55,6 +55,9 @@ spec:
{{ .Values.labels.volume.node_selector_key }}: {{ .Values.labels.volume.node_selector_value }}
{{- if .Values.pod.useHostNetwork.volume }}
hostNetwork: true
{{- end }}
{{- if .Values.conf.enable_iscsi }}
hostIPC: true
{{- end }}
initContainers:
{{ tuple $envAll "volume" $mounts_cinder_volume_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }}
@ -224,6 +227,14 @@ spec:
{{- if .Values.conf.enable_iscsi }}
- name: host-rootfs
mountPath: /mnt/host-rootfs
{{- if or ( gt .Capabilities.KubeVersion.Major "1" ) ( ge .Capabilities.KubeVersion.Minor "10" ) }}
mountPropagation: HostToContainer
{{- end }}
- name: host-dev
mountPath: /dev
{{- if or ( gt .Capabilities.KubeVersion.Major "1" ) ( ge .Capabilities.KubeVersion.Minor "10" ) }}
mountPropagation: Bidirectional
{{- end }}
- name: runlock
mountPath: /run/lock
- name: etciscsi
@ -281,6 +292,9 @@ spec:
- name: host-rootfs
hostPath:
path: /
- name: host-dev
hostPath:
path: /dev
- name: runlock
hostPath:
path: /run/lock