From 161170bf96c1a63505c128439d9b93d39d85f7fe Mon Sep 17 00:00:00 2001 From: Steve Wilkerson Date: Mon, 15 May 2017 19:18:01 +0000 Subject: [PATCH] Move init containers from annotation to official object With 1.6, init containers are officially part of the kubernetes API. This changes the format of the helm template for the entrypoint container from json to yaml, and updates the charts accordingly. Co-Authored-By: Pete Birley Change-Id: I569566ce4b031d107af2d38483040a26210bec45 --- barbican/templates/deployment-api.yaml | 5 +- barbican/templates/job-db-init.yaml | 7 +- barbican/templates/job-db-sync.yaml | 7 +- barbican/templates/job-ks-endpoints.yaml | 7 +- barbican/templates/job-ks-service.yaml | 7 +- barbican/templates/job-ks-user.yaml | 7 +- cinder/templates/deployment-api.yaml | 5 +- cinder/templates/deployment-backup.yaml | 5 +- cinder/templates/deployment-scheduler.yaml | 5 +- cinder/templates/deployment-volume.yaml | 5 +- cinder/templates/job-db-init.yaml | 7 +- cinder/templates/job-db-sync.yaml | 7 +- cinder/templates/job-ks-endpoints.yaml | 7 +- cinder/templates/job-ks-service.yaml | 7 +- cinder/templates/job-ks-user.yaml | 7 +- cinder/templates/job_bootstrap.yaml | 7 +- glance/templates/deployment-api.yaml | 5 +- glance/templates/deployment-registry.yaml | 5 +- glance/templates/job-bootstrap.yaml | 7 +- glance/templates/job-db-init.yaml | 7 +- glance/templates/job-db-sync.yaml | 7 +- glance/templates/job-ks-endpoints.yaml | 7 +- glance/templates/job-ks-service.yaml | 7 +- glance/templates/job-ks-user.yaml | 7 +- glance/templates/pod-rally-test.yaml | 5 +- heat/templates/deployment-api.yaml | 5 +- heat/templates/deployment-cfn.yaml | 5 +- heat/templates/deployment-cloudwatch.yaml | 5 +- heat/templates/job-db-init.yaml | 7 +- heat/templates/job-db-sync.yaml | 7 +- heat/templates/job-ks-endpoints.yaml | 7 +- heat/templates/job-ks-service.yaml | 7 +- heat/templates/job-ks-user.yaml | 7 +- heat/templates/statefulset-engine.yaml | 6 +- .../snippets/_k8s_init_dep_check.tpl | 81 +++++++------------ horizon/templates/deployment.yaml | 5 +- keystone/templates/deployment.yaml | 5 +- keystone/templates/job-db-init.yaml | 6 +- keystone/templates/job-db-sync.yaml | 5 +- keystone/templates/pod-rally-test.yaml | 5 +- magnum/templates/deployment-api.yaml | 5 +- magnum/templates/job-db-init.yaml | 7 +- magnum/templates/job-db-sync.yaml | 7 +- magnum/templates/job-ks-endpoints.yaml | 7 +- magnum/templates/job-ks-service.yaml | 7 +- magnum/templates/job-ks-user.yaml | 7 +- magnum/templates/statefulset-conductor.yaml | 6 +- mistral/templates/deployment-api.yaml | 5 +- mistral/templates/deployment-executor.yaml | 5 +- mistral/templates/job-db-init.yaml | 7 +- mistral/templates/job-db-sync.yaml | 7 +- mistral/templates/job-ks-endpoints.yaml | 7 +- mistral/templates/job-ks-service.yaml | 8 +- mistral/templates/job-ks-user.yaml | 8 +- mistral/templates/statefulset-engine.yaml | 6 +- .../templates/statefulset-event-engine.yaml | 6 +- neutron/templates/daemonset-dhcp-agent.yaml | 5 +- neutron/templates/daemonset-l3-agent.yaml | 5 +- .../templates/daemonset-metadata-agent.yaml | 5 +- neutron/templates/daemonset-ovs-agent.yaml | 5 +- neutron/templates/deployment-server.yaml | 5 +- neutron/templates/job-db-init.yaml | 7 +- neutron/templates/job-db-sync.yaml | 7 +- neutron/templates/job-ks-endpoints.yaml | 7 +- neutron/templates/job-ks-service.yaml | 7 +- neutron/templates/job-ks-user.yaml | 7 +- nova/templates/daemonset-compute.yaml | 5 +- nova/templates/daemonset-libvirt.yaml | 5 +- nova/templates/deployment-api-metadata.yaml | 5 +- nova/templates/deployment-api-osapi.yaml | 5 +- nova/templates/deployment-conductor.yaml | 5 +- nova/templates/deployment-consoleauth.yaml | 5 +- nova/templates/deployment-scheduler.yaml | 5 +- nova/templates/job-bootstrap.yaml | 7 +- nova/templates/job-db-init.yaml | 7 +- nova/templates/job-db-sync.yaml | 7 +- nova/templates/job-ks-endpoints.yaml | 7 +- nova/templates/job-ks-service.yaml | 7 +- nova/templates/job-ks-user.yaml | 7 +- rabbitmq/templates/deployment.yaml | 5 +- senlin/templates/deployment-api.yaml | 5 +- senlin/templates/job-db-init.yaml | 7 +- senlin/templates/job-db-sync.yaml | 7 +- senlin/templates/job-ks-endpoints.yaml | 7 +- senlin/templates/job-ks-service.yaml | 7 +- senlin/templates/job-ks-user.yaml | 7 +- senlin/templates/statefulset-engine.yaml | 6 +- 87 files changed, 199 insertions(+), 416 deletions(-) diff --git a/barbican/templates/deployment-api.yaml b/barbican/templates/deployment-api.yaml index 9d5d3970e8..a1141e180c 100644 --- a/barbican/templates/deployment-api.yaml +++ b/barbican/templates/deployment-api.yaml @@ -35,12 +35,11 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_barbican_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_barbican_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: barbican-api image: {{ .Values.images.api }} diff --git a/barbican/templates/job-db-init.yaml b/barbican/templates/job-db-init.yaml index f8b4902478..3ccf077d54 100644 --- a/barbican/templates/job-db-init.yaml +++ b/barbican/templates/job-db-init.yaml @@ -18,15 +18,12 @@ metadata: name: barbican-db-init spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: barbican-db-init image: {{ .Values.images.db_init }} diff --git a/barbican/templates/job-db-sync.yaml b/barbican/templates/job-db-sync.yaml index f4cef4e1a4..11a0076698 100644 --- a/barbican/templates/job-db-sync.yaml +++ b/barbican/templates/job-db-sync.yaml @@ -18,15 +18,12 @@ metadata: name: barbican-db-sync spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: barbican-db-sync image: {{ .Values.images.db_sync }} diff --git a/barbican/templates/job-ks-endpoints.yaml b/barbican/templates/job-ks-endpoints.yaml index 46fbb98406..359b74d31c 100644 --- a/barbican/templates/job-ks-endpoints.yaml +++ b/barbican/templates/job-ks-endpoints.yaml @@ -19,15 +19,12 @@ metadata: name: barbican-ks-endpoints spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "key-manager" }} {{- range $key2, $osServiceEndPoint := tuple "admin" "internal" "public" }} diff --git a/barbican/templates/job-ks-service.yaml b/barbican/templates/job-ks-service.yaml index 3a3b2ac08c..652d5dc789 100644 --- a/barbican/templates/job-ks-service.yaml +++ b/barbican/templates/job-ks-service.yaml @@ -19,15 +19,12 @@ metadata: name: barbican-ks-service spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "key-manager" }} - name: {{ $osServiceType }}-ks-service-registration diff --git a/barbican/templates/job-ks-user.yaml b/barbican/templates/job-ks-user.yaml index 9e2cb7ebb4..2bd5fb0c1f 100644 --- a/barbican/templates/job-ks-user.yaml +++ b/barbican/templates/job-ks-user.yaml @@ -20,15 +20,12 @@ metadata: name: barbican-ks-user spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: barbican-ks-user image: {{ .Values.images.ks_user }} diff --git a/cinder/templates/deployment-api.yaml b/cinder/templates/deployment-api.yaml index b457edb5bd..599c43ca59 100644 --- a/cinder/templates/deployment-api.yaml +++ b/cinder/templates/deployment-api.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_cinder_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.api.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_cinder_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: cinder-api image: {{ .Values.images.api }} diff --git a/cinder/templates/deployment-backup.yaml b/cinder/templates/deployment-backup.yaml index b6f5b61c04..6b542e461c 100644 --- a/cinder/templates/deployment-backup.yaml +++ b/cinder/templates/deployment-backup.yaml @@ -37,12 +37,11 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_cinder_backup_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_cinder_backup_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: cinder-backup image: {{ .Values.images.backup }} diff --git a/cinder/templates/deployment-scheduler.yaml b/cinder/templates/deployment-scheduler.yaml index 68140a9ea5..57fc9788b3 100644 --- a/cinder/templates/deployment-scheduler.yaml +++ b/cinder/templates/deployment-scheduler.yaml @@ -37,12 +37,11 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_cinder_scheduler_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_cinder_scheduler_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: cinder-scheduler image: {{ .Values.images.scheduler }} diff --git a/cinder/templates/deployment-volume.yaml b/cinder/templates/deployment-volume.yaml index d9b42a2c07..c32c49decc 100644 --- a/cinder/templates/deployment-volume.yaml +++ b/cinder/templates/deployment-volume.yaml @@ -37,12 +37,11 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_cinder_volume_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_cinder_volume_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: cinder-volume image: {{ .Values.images.volume }} diff --git a/cinder/templates/job-db-init.yaml b/cinder/templates/job-db-init.yaml index ca6b29e6ed..6fed2b0f12 100644 --- a/cinder/templates/job-db-init.yaml +++ b/cinder/templates/job-db-init.yaml @@ -20,15 +20,12 @@ metadata: name: cinder-db-init spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: cinder-db-init image: {{ .Values.images.db_init | quote }} diff --git a/cinder/templates/job-db-sync.yaml b/cinder/templates/job-db-sync.yaml index 3d6a60e281..5d840cc36b 100644 --- a/cinder/templates/job-db-sync.yaml +++ b/cinder/templates/job-db-sync.yaml @@ -20,15 +20,12 @@ metadata: name: cinder-db-sync spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: cinder-db-sync image: {{ .Values.images.db_sync }} diff --git a/cinder/templates/job-ks-endpoints.yaml b/cinder/templates/job-ks-endpoints.yaml index 0de91916d7..8f42bde76e 100644 --- a/cinder/templates/job-ks-endpoints.yaml +++ b/cinder/templates/job-ks-endpoints.yaml @@ -21,15 +21,12 @@ metadata: name: cinder-ks-endpoints spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "volume" "volumev2" "volumev3" }} {{- range $key2, $osServiceEndPoint := tuple "admin" "internal" "public" }} diff --git a/cinder/templates/job-ks-service.yaml b/cinder/templates/job-ks-service.yaml index f75b6f274b..6f10890027 100644 --- a/cinder/templates/job-ks-service.yaml +++ b/cinder/templates/job-ks-service.yaml @@ -21,15 +21,12 @@ metadata: name: cinder-ks-service spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "volume" "volumev2" "volumev3" }} - name: {{ $osServiceType }}-ks-service-registration diff --git a/cinder/templates/job-ks-user.yaml b/cinder/templates/job-ks-user.yaml index 6fb000a76c..e3315c255b 100644 --- a/cinder/templates/job-ks-user.yaml +++ b/cinder/templates/job-ks-user.yaml @@ -22,15 +22,12 @@ metadata: name: cinder-ks-user spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: cinder-ks-user image: {{ .Values.images.ks_user }} diff --git a/cinder/templates/job_bootstrap.yaml b/cinder/templates/job_bootstrap.yaml index 3eeb2eba50..dbfe4708da 100644 --- a/cinder/templates/job_bootstrap.yaml +++ b/cinder/templates/job_bootstrap.yaml @@ -22,15 +22,12 @@ metadata: name: cinder-bootstrap spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: cinder-bootstrap image: {{ .Values.images.bootstrap }} diff --git a/glance/templates/deployment-api.yaml b/glance/templates/deployment-api.yaml index 49fd85a4fb..5ba499966d 100644 --- a/glance/templates/deployment-api.yaml +++ b/glance/templates/deployment-api.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_glance_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.api.timeout | default "600" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_glance_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: glance-api image: {{ .Values.images.api }} diff --git a/glance/templates/deployment-registry.yaml b/glance/templates/deployment-registry.yaml index 9c79023646..cf27b670fb 100644 --- a/glance/templates/deployment-registry.yaml +++ b/glance/templates/deployment-registry.yaml @@ -29,13 +29,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_glance_registry_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.registry.timeout | default "600" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_glance_registry_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: glance-registry image: {{ .Values.images.registry }} diff --git a/glance/templates/job-bootstrap.yaml b/glance/templates/job-bootstrap.yaml index f3386fd219..faa31e88e1 100644 --- a/glance/templates/job-bootstrap.yaml +++ b/glance/templates/job-bootstrap.yaml @@ -21,15 +21,12 @@ metadata: name: glance-bootstrap spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: glance-bootstrap image: {{ .Values.images.db_init }} diff --git a/glance/templates/job-db-init.yaml b/glance/templates/job-db-init.yaml index 9e0b82e1ff..20868eae72 100644 --- a/glance/templates/job-db-init.yaml +++ b/glance/templates/job-db-init.yaml @@ -20,15 +20,12 @@ metadata: name: glance-db-init spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: glance-db-init image: {{ .Values.images.db_init }} diff --git a/glance/templates/job-db-sync.yaml b/glance/templates/job-db-sync.yaml index 1040c5ccf2..1102dd4cda 100644 --- a/glance/templates/job-db-sync.yaml +++ b/glance/templates/job-db-sync.yaml @@ -20,15 +20,12 @@ metadata: name: glance-db-sync spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: glance-db-sync image: {{ .Values.images.db_sync }} diff --git a/glance/templates/job-ks-endpoints.yaml b/glance/templates/job-ks-endpoints.yaml index 2046838561..29c0706584 100644 --- a/glance/templates/job-ks-endpoints.yaml +++ b/glance/templates/job-ks-endpoints.yaml @@ -21,15 +21,12 @@ metadata: name: glance-ks-endpoints spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "image" }} {{- range $key2, $osServiceEndPoint := tuple "admin" "internal" "public" }} diff --git a/glance/templates/job-ks-service.yaml b/glance/templates/job-ks-service.yaml index 6e6a74face..23252a89b2 100644 --- a/glance/templates/job-ks-service.yaml +++ b/glance/templates/job-ks-service.yaml @@ -21,15 +21,12 @@ metadata: name: glance-ks-service spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "image" }} - name: {{ $osServiceType }}-ks-service-registration diff --git a/glance/templates/job-ks-user.yaml b/glance/templates/job-ks-user.yaml index a722f09552..1fdd24e192 100644 --- a/glance/templates/job-ks-user.yaml +++ b/glance/templates/job-ks-user.yaml @@ -22,15 +22,12 @@ metadata: name: glance-ks-user spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: glance-ks-user image: {{ .Values.images.ks_user }} diff --git a/glance/templates/pod-rally-test.yaml b/glance/templates/pod-rally-test.yaml index 0792487406..f4d8d983f0 100644 --- a/glance/templates/pod-rally-test.yaml +++ b/glance/templates/pod-rally-test.yaml @@ -24,11 +24,10 @@ metadata: name: "{{.Release.Name}}-rally-test" annotations: "helm.sh/hook": test-success - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_glance_tests_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: Never + initContainers: +{{ tuple $envAll $dependencies $mounts_glance_tests_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 4 }} containers: - name: {{.Release.Name}}-token-issue-test image: {{ .Values.images.test }} diff --git a/heat/templates/deployment-api.yaml b/heat/templates/deployment-api.yaml index 234a660513..33f9aab070 100644 --- a/heat/templates/deployment-api.yaml +++ b/heat/templates/deployment-api.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_heat_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.api.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_heat_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: heat-api image: {{ .Values.images.api }} diff --git a/heat/templates/deployment-cfn.yaml b/heat/templates/deployment-cfn.yaml index e9e6ece885..8dc251a95a 100644 --- a/heat/templates/deployment-cfn.yaml +++ b/heat/templates/deployment-cfn.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_heat_cfn_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.cfn.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_heat_cfn_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: heat-cfn image: {{ .Values.images.cfn }} diff --git a/heat/templates/deployment-cloudwatch.yaml b/heat/templates/deployment-cloudwatch.yaml index 749e726d65..50fe32cbab 100644 --- a/heat/templates/deployment-cloudwatch.yaml +++ b/heat/templates/deployment-cloudwatch.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_heat_cloudwatch_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.cloudwatch.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_heat_cloudwatch_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: heat-cloudwatch image: {{ .Values.images.cloudwatch }} diff --git a/heat/templates/job-db-init.yaml b/heat/templates/job-db-init.yaml index e921a2cfa3..de957d04e1 100644 --- a/heat/templates/job-db-init.yaml +++ b/heat/templates/job-db-init.yaml @@ -20,15 +20,12 @@ metadata: name: heat-db-init spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: heat-db-init image: {{ .Values.images.db_init | quote }} diff --git a/heat/templates/job-db-sync.yaml b/heat/templates/job-db-sync.yaml index 0458db2218..70c486f711 100644 --- a/heat/templates/job-db-sync.yaml +++ b/heat/templates/job-db-sync.yaml @@ -20,15 +20,12 @@ metadata: name: heat-db-sync spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: heat-db-sync image: {{ .Values.images.db_sync }} diff --git a/heat/templates/job-ks-endpoints.yaml b/heat/templates/job-ks-endpoints.yaml index 87e94923a0..8153f5e4b5 100644 --- a/heat/templates/job-ks-endpoints.yaml +++ b/heat/templates/job-ks-endpoints.yaml @@ -21,15 +21,12 @@ metadata: name: heat-ks-endpoints spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "orchestration" "cloudformation" }} {{- range $key2, $osServiceEndPoint := tuple "admin" "internal" "public" }} diff --git a/heat/templates/job-ks-service.yaml b/heat/templates/job-ks-service.yaml index b9fe40b211..fbe33bc266 100644 --- a/heat/templates/job-ks-service.yaml +++ b/heat/templates/job-ks-service.yaml @@ -21,15 +21,12 @@ metadata: name: heat-ks-service spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "orchestration" "cloudformation" }} - name: {{ $osServiceType }}-ks-service-registration diff --git a/heat/templates/job-ks-user.yaml b/heat/templates/job-ks-user.yaml index ecaf724c01..f8bc02893f 100644 --- a/heat/templates/job-ks-user.yaml +++ b/heat/templates/job-ks-user.yaml @@ -25,15 +25,12 @@ metadata: name: heat-ks-user spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: heat-ks-user image: {{ .Values.images.ks_user }} diff --git a/heat/templates/statefulset-engine.yaml b/heat/templates/statefulset-engine.yaml index a51483ff95..1e34c9ff75 100644 --- a/heat/templates/statefulset-engine.yaml +++ b/heat/templates/statefulset-engine.yaml @@ -27,13 +27,11 @@ spec: metadata: labels: app: heat-engine - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_heat_engine_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_heat_engine_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: heat-engine image: {{ .Values.images.engine }} diff --git a/helm-toolkit/templates/snippets/_k8s_init_dep_check.tpl b/helm-toolkit/templates/snippets/_k8s_init_dep_check.tpl index 5644ce4681..b3d9ba6bca 100644 --- a/helm-toolkit/templates/snippets/_k8s_init_dep_check.tpl +++ b/helm-toolkit/templates/snippets/_k8s_init_dep_check.tpl @@ -16,58 +16,31 @@ {{- $envAll := index . 0 -}} {{- $deps := index . 1 -}} {{- $mounts := index . 2 -}} -{ - "name": "init", - "image": {{ $envAll.Values.images.dep_check | quote }}, - "imagePullPolicy": {{ $envAll.Values.images.pull_policy | quote }}, - "env": [ - { - "name": "POD_NAME", - {{- if $deps.pod -}} - "value": "{{ index $deps.pod 0 }}" - {{- else -}} - "valueFrom": { - "fieldRef": { - "APIVersion": "v1", - "fieldPath": "metadata.name" - } - } - {{- end -}} - }, - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "APIVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - }, - { - "name": "INTERFACE_NAME", - "value": "eth0" - }, - { - "name": "DEPENDENCY_SERVICE", - "value": "{{ include "helm-toolkit.utils.joinListWithComma" $deps.service }}" - }, - { - "name": "DEPENDENCY_JOBS", - "value": "{{ include "helm-toolkit.utils.joinListWithComma" $deps.jobs }}" - }, - { - "name": "DEPENDENCY_DAEMONSET", - "value": "{{ include "helm-toolkit.utils.joinListWithComma" $deps.daemonset }}" - }, - { - "name": "DEPENDENCY_CONTAINER", - "value": "{{ include "helm-toolkit.utils.joinListWithComma" $deps.container }}" - }, - { - "name": "COMMAND", - "value": "echo done" - } - ], -"volumeMounts": {{ $mounts | default "[]"}} -} +- name: init + image: {{ $envAll.Values.images.dep_check }} + imagePullPolicy: {{ $envAll.Values.images.pull_policy }} + env: + - name: POD_NAME + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.name + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + - name: INTERFACE_NAME + value: eth0 + - name: DEPENDENCY_SERVICE + value: "{{ include "helm-toolkit.utils.joinListWithComma" $deps.service }}" + - name: DEPENDENCY_JOBS + value: "{{ include "helm-toolkit.utils.joinListWithComma" $deps.jobs }}" + - name: DEPENDENCY_DAEMONSET + value: "{{ include "helm-toolkit.utils.joinListWithComma" $deps.daemonset }}" + - name: DEPENDENCY_CONTAINER + value: "{{ include "helm-toolkit.utils.joinListWithComma" $deps.container }}" + - name: COMMAND + value: "echo done" + volumeMounts: {{ $mounts | default "[]"}} {{- end -}} diff --git a/horizon/templates/deployment.yaml b/horizon/templates/deployment.yaml index 4971dfe244..59a37f85f7 100644 --- a/horizon/templates/deployment.yaml +++ b/horizon/templates/deployment.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_horizon_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.horizon.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_horizon_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: horizon image: {{ .Values.images.horizon }} diff --git a/keystone/templates/deployment.yaml b/keystone/templates/deployment.yaml index e0c8474a48..9a5060e8d5 100644 --- a/keystone/templates/deployment.yaml +++ b/keystone/templates/deployment.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_keystone_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.api.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_keystone_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: keystone-api image: {{ .Values.images.api }} diff --git a/keystone/templates/job-db-init.yaml b/keystone/templates/job-db-init.yaml index 4c3abbdea6..a75763f4f3 100644 --- a/keystone/templates/job-db-init.yaml +++ b/keystone/templates/job-db-init.yaml @@ -24,14 +24,12 @@ metadata: spec: template: metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_keystone_db_init_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_keystone_db_init_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: keystone-db-init image: {{ .Values.images.db_init }} diff --git a/keystone/templates/job-db-sync.yaml b/keystone/templates/job-db-sync.yaml index 5296e790d3..26cd8776f9 100644 --- a/keystone/templates/job-db-sync.yaml +++ b/keystone/templates/job-db-sync.yaml @@ -24,13 +24,12 @@ spec: template: metadata: annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_keystone_db_sync_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_keystone_db_sync_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: keystone-db-sync image: {{ .Values.images.db_sync }} diff --git a/keystone/templates/pod-rally-test.yaml b/keystone/templates/pod-rally-test.yaml index 01777eb862..1f526e2082 100644 --- a/keystone/templates/pod-rally-test.yaml +++ b/keystone/templates/pod-rally-test.yaml @@ -24,11 +24,10 @@ metadata: name: "{{.Release.Name}}-rally-test" annotations: "helm.sh/hook": test-success - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_keystone_tests_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: Never + initContainers: +{{ tuple $envAll $dependencies $mounts_keystone_tests_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 4 }} containers: - name: {{.Release.Name}}-token-issue-test image: {{ .Values.images.test }} diff --git a/magnum/templates/deployment-api.yaml b/magnum/templates/deployment-api.yaml index 78815956ec..d5d1229178 100644 --- a/magnum/templates/deployment-api.yaml +++ b/magnum/templates/deployment-api.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_magnum_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.api.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_magnum_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: magnum-api image: {{ .Values.images.api }} diff --git a/magnum/templates/job-db-init.yaml b/magnum/templates/job-db-init.yaml index 7806d08ec1..fa892b4f2d 100644 --- a/magnum/templates/job-db-init.yaml +++ b/magnum/templates/job-db-init.yaml @@ -20,15 +20,12 @@ metadata: name: magnum-db-init spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: magnum-db-init image: {{ .Values.images.db_init | quote }} diff --git a/magnum/templates/job-db-sync.yaml b/magnum/templates/job-db-sync.yaml index d38322ebba..59c9099c3c 100644 --- a/magnum/templates/job-db-sync.yaml +++ b/magnum/templates/job-db-sync.yaml @@ -20,15 +20,12 @@ metadata: name: magnum-db-sync spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: magnum-db-sync image: {{ .Values.images.db_sync }} diff --git a/magnum/templates/job-ks-endpoints.yaml b/magnum/templates/job-ks-endpoints.yaml index 9510864f56..fd7df3ee32 100644 --- a/magnum/templates/job-ks-endpoints.yaml +++ b/magnum/templates/job-ks-endpoints.yaml @@ -21,15 +21,12 @@ metadata: name: magnum-ks-endpoints spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "container-infra" }} {{- range $key2, $osServiceEndPoint := tuple "admin" "internal" "public" }} diff --git a/magnum/templates/job-ks-service.yaml b/magnum/templates/job-ks-service.yaml index 1ab14f3e45..056db19acf 100644 --- a/magnum/templates/job-ks-service.yaml +++ b/magnum/templates/job-ks-service.yaml @@ -21,15 +21,12 @@ metadata: name: magnum-ks-service spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "container-infra" }} - name: {{ $osServiceType }}-ks-service-registration diff --git a/magnum/templates/job-ks-user.yaml b/magnum/templates/job-ks-user.yaml index e45dbc6486..40be7e2d1b 100644 --- a/magnum/templates/job-ks-user.yaml +++ b/magnum/templates/job-ks-user.yaml @@ -22,15 +22,12 @@ metadata: name: magnum-ks-user spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: magnum-ks-user image: {{ .Values.images.ks_user }} diff --git a/magnum/templates/statefulset-conductor.yaml b/magnum/templates/statefulset-conductor.yaml index 65c5dfcfb1..885d04bfb7 100644 --- a/magnum/templates/statefulset-conductor.yaml +++ b/magnum/templates/statefulset-conductor.yaml @@ -27,13 +27,11 @@ spec: metadata: labels: app: magnum-conductor - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_magnum_conductor_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_magnum_conductor_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: magnum-conductor image: {{ .Values.images.conductor }} diff --git a/mistral/templates/deployment-api.yaml b/mistral/templates/deployment-api.yaml index 5d061bd409..ae86d68613 100644 --- a/mistral/templates/deployment-api.yaml +++ b/mistral/templates/deployment-api.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_mistral_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.api.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_mistral_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: mistral-api image: {{ .Values.images.api }} diff --git a/mistral/templates/deployment-executor.yaml b/mistral/templates/deployment-executor.yaml index 3c19d7b712..e6ee448110 100644 --- a/mistral/templates/deployment-executor.yaml +++ b/mistral/templates/deployment-executor.yaml @@ -37,12 +37,11 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_mistral_executor_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_mistral_executor_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: mistral-executor image: {{ .Values.images.executor }} diff --git a/mistral/templates/job-db-init.yaml b/mistral/templates/job-db-init.yaml index d5732b5f24..39422fa746 100644 --- a/mistral/templates/job-db-init.yaml +++ b/mistral/templates/job-db-init.yaml @@ -20,15 +20,12 @@ metadata: name: mistral-db-init spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: mistral-db-init image: {{ .Values.images.db_init | quote }} diff --git a/mistral/templates/job-db-sync.yaml b/mistral/templates/job-db-sync.yaml index fec8b22999..50c318985b 100644 --- a/mistral/templates/job-db-sync.yaml +++ b/mistral/templates/job-db-sync.yaml @@ -21,15 +21,12 @@ metadata: name: mistral-db-sync spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: mistral-db-sync image: {{ .Values.images.db_sync }} diff --git a/mistral/templates/job-ks-endpoints.yaml b/mistral/templates/job-ks-endpoints.yaml index 2258286184..c022d13473 100644 --- a/mistral/templates/job-ks-endpoints.yaml +++ b/mistral/templates/job-ks-endpoints.yaml @@ -21,15 +21,12 @@ metadata: name: mistral-ks-endpoints spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "workflow" }} {{- range $key2, $osServiceEndPoint := tuple "admin" "internal" "public" }} diff --git a/mistral/templates/job-ks-service.yaml b/mistral/templates/job-ks-service.yaml index a1280424ab..ab0a12780d 100644 --- a/mistral/templates/job-ks-service.yaml +++ b/mistral/templates/job-ks-service.yaml @@ -21,15 +21,12 @@ metadata: name: mistral-ks-service spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "workflow" }} - name: {{ $osServiceType }}-ks-service-registration @@ -65,4 +62,3 @@ spec: - name: ks-service-sh configMap: name: mistral-bin - diff --git a/mistral/templates/job-ks-user.yaml b/mistral/templates/job-ks-user.yaml index ad52d8c3fc..0761f8abe7 100644 --- a/mistral/templates/job-ks-user.yaml +++ b/mistral/templates/job-ks-user.yaml @@ -22,15 +22,12 @@ metadata: name: mistral-ks-user spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: mistral-ks-user image: {{ .Values.images.ks_user }} @@ -67,4 +64,3 @@ spec: - name: ks-user-sh configMap: name: mistral-bin - diff --git a/mistral/templates/statefulset-engine.yaml b/mistral/templates/statefulset-engine.yaml index 82520709d2..2a336b1a13 100644 --- a/mistral/templates/statefulset-engine.yaml +++ b/mistral/templates/statefulset-engine.yaml @@ -27,13 +27,11 @@ spec: metadata: labels: app: mistral-engine - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_mistral_engine_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_mistral_engine_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: mistral-engine image: {{ .Values.images.engine }} diff --git a/mistral/templates/statefulset-event-engine.yaml b/mistral/templates/statefulset-event-engine.yaml index a67d93bda1..10b4665db7 100644 --- a/mistral/templates/statefulset-event-engine.yaml +++ b/mistral/templates/statefulset-event-engine.yaml @@ -27,13 +27,11 @@ spec: metadata: labels: app: mistral-event-engine - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_mistral_event_engine_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_mistral_event_engine_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: mistral-event-engine image: {{ .Values.images.event_engine }} diff --git a/neutron/templates/daemonset-dhcp-agent.yaml b/neutron/templates/daemonset-dhcp-agent.yaml index 4a1fc76fc4..8a390aaee5 100644 --- a/neutron/templates/daemonset-dhcp-agent.yaml +++ b/neutron/templates/daemonset-dhcp-agent.yaml @@ -28,9 +28,6 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_neutron_dhcp_agent_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.agent.dhcp.node_selector_key }}: {{ .Values.labels.agent.dhcp.node_selector_value }} @@ -38,6 +35,8 @@ spec: runAsUser: 0 dnsPolicy: ClusterFirst hostNetwork: true + initContainers: +{{ tuple $envAll $dependencies $mounts_neutron_dhcp_agent_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: neutron-dhcp-agent image: {{ .Values.images.dhcp }} diff --git a/neutron/templates/daemonset-l3-agent.yaml b/neutron/templates/daemonset-l3-agent.yaml index 7c0ab707a3..d19f4da479 100644 --- a/neutron/templates/daemonset-l3-agent.yaml +++ b/neutron/templates/daemonset-l3-agent.yaml @@ -28,9 +28,6 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_neutron_l3_agent_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.agent.l3.node_selector_key }}: {{ .Values.labels.agent.l3.node_selector_value }} @@ -38,6 +35,8 @@ spec: runAsUser: 0 dnsPolicy: ClusterFirst hostNetwork: true + initContainers: +{{ tuple $envAll $dependencies $mounts_neutron_l3_agent_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: neutron-l3-agent image: {{ .Values.images.l3 }} diff --git a/neutron/templates/daemonset-metadata-agent.yaml b/neutron/templates/daemonset-metadata-agent.yaml index de2b466262..1bb92530cb 100644 --- a/neutron/templates/daemonset-metadata-agent.yaml +++ b/neutron/templates/daemonset-metadata-agent.yaml @@ -28,9 +28,6 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_neutron_metadata_agent_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.agent.metadata.node_selector_key }}: {{ .Values.labels.agent.metadata.node_selector_value }} @@ -38,6 +35,8 @@ spec: runAsUser: 0 dnsPolicy: ClusterFirst hostNetwork: true + initContainers: +{{ tuple $envAll $dependencies $mounts_neutron_metadata_agent_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: neutron-metadata-agent image: {{ .Values.images.metadata }} diff --git a/neutron/templates/daemonset-ovs-agent.yaml b/neutron/templates/daemonset-ovs-agent.yaml index 42886ac4ed..6e3fe76732 100644 --- a/neutron/templates/daemonset-ovs-agent.yaml +++ b/neutron/templates/daemonset-ovs-agent.yaml @@ -28,9 +28,6 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_neutron_ovs_agent_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.ovs.node_selector_key }}: {{ .Values.labels.ovs.node_selector_value }} @@ -38,6 +35,8 @@ spec: runAsUser: 0 dnsPolicy: ClusterFirst hostNetwork: true + initContainers: +{{ tuple $envAll $dependencies $mounts_neutron_ovs_agent_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: ovs-agent image: {{ .Values.images.neutron_openvswitch_agent }} diff --git a/neutron/templates/deployment-server.yaml b/neutron/templates/deployment-server.yaml index d91e652f64..1465d28100 100644 --- a/neutron/templates/deployment-server.yaml +++ b/neutron/templates/deployment-server.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_neutron_server_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.server.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_neutron_server_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: neutron-server image: {{ .Values.images.server }} diff --git a/neutron/templates/job-db-init.yaml b/neutron/templates/job-db-init.yaml index 9ac29bfb60..a857da95d6 100644 --- a/neutron/templates/job-db-init.yaml +++ b/neutron/templates/job-db-init.yaml @@ -20,15 +20,12 @@ metadata: name: neutron-db-init spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: neutron-db-init image: {{ .Values.images.db_init }} diff --git a/neutron/templates/job-db-sync.yaml b/neutron/templates/job-db-sync.yaml index 560dbce97b..18c99a80ca 100644 --- a/neutron/templates/job-db-sync.yaml +++ b/neutron/templates/job-db-sync.yaml @@ -20,15 +20,12 @@ metadata: name: neutron-db-sync spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: neutron-db-sync image: {{ .Values.images.db_sync }} diff --git a/neutron/templates/job-ks-endpoints.yaml b/neutron/templates/job-ks-endpoints.yaml index 5b7f51d3ca..29bbf79db2 100644 --- a/neutron/templates/job-ks-endpoints.yaml +++ b/neutron/templates/job-ks-endpoints.yaml @@ -21,15 +21,12 @@ metadata: name: neutron-ks-endpoints spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "network" }} {{- range $key2, $osServiceEndPoint := tuple "admin" "internal" "public" }} diff --git a/neutron/templates/job-ks-service.yaml b/neutron/templates/job-ks-service.yaml index 498ec688ff..8611d86899 100644 --- a/neutron/templates/job-ks-service.yaml +++ b/neutron/templates/job-ks-service.yaml @@ -21,15 +21,12 @@ metadata: name: neutron-ks-service spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "network" }} - name: {{ $osServiceType }}-ks-service-registration diff --git a/neutron/templates/job-ks-user.yaml b/neutron/templates/job-ks-user.yaml index 6409ac71b9..4675f8ebf1 100644 --- a/neutron/templates/job-ks-user.yaml +++ b/neutron/templates/job-ks-user.yaml @@ -22,15 +22,12 @@ metadata: name: neutron-ks-user spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: neutron-ks-user image: {{ .Values.images.ks_user }} diff --git a/nova/templates/daemonset-compute.yaml b/nova/templates/daemonset-compute.yaml index 7488fc3304..1d7a38c269 100644 --- a/nova/templates/daemonset-compute.yaml +++ b/nova/templates/daemonset-compute.yaml @@ -29,9 +29,6 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_nova_compute_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.agent.compute.node_selector_key }}: {{ .Values.labels.agent.compute.node_selector_value }} @@ -40,6 +37,8 @@ spec: hostNetwork: true hostPID: true dnsPolicy: ClusterFirst + initContainers: +{{ tuple $envAll $dependencies $mounts_nova_compute_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: nova-compute image: {{ .Values.images.compute }} diff --git a/nova/templates/daemonset-libvirt.yaml b/nova/templates/daemonset-libvirt.yaml index 5b66b06cd9..f39a03cdc9 100644 --- a/nova/templates/daemonset-libvirt.yaml +++ b/nova/templates/daemonset-libvirt.yaml @@ -28,9 +28,6 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_nova_libvirt_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.agent.libvirt.node_selector_key }}: {{ .Values.labels.agent.libvirt.node_selector_value }} @@ -39,6 +36,8 @@ spec: hostNetwork: true hostPID: true dnsPolicy: ClusterFirst + initContainers: +{{ tuple $envAll $dependencies $mounts_nova_libvirt_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: nova-libvirt image: {{ .Values.images.libvirt }} diff --git a/nova/templates/deployment-api-metadata.yaml b/nova/templates/deployment-api-metadata.yaml index 1a73c96919..e18849e16f 100644 --- a/nova/templates/deployment-api-metadata.yaml +++ b/nova/templates/deployment-api-metadata.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_nova_api_metadata_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.api_metadata.node_selector_key }}: {{ .Values.labels.api_metadata.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.metadata.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_nova_api_metadata_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: nova-api image: {{ .Values.images.api }} diff --git a/nova/templates/deployment-api-osapi.yaml b/nova/templates/deployment-api-osapi.yaml index 0320ab9930..7ef05f81e9 100644 --- a/nova/templates/deployment-api-osapi.yaml +++ b/nova/templates/deployment-api-osapi.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_nova_api_osapi_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.osapi.node_selector_key }}: {{ .Values.labels.osapi.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.osapi.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_nova_api_osapi_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: nova-osapi image: {{ .Values.images.api }} diff --git a/nova/templates/deployment-conductor.yaml b/nova/templates/deployment-conductor.yaml index 29c2a85a1a..12d6eea010 100644 --- a/nova/templates/deployment-conductor.yaml +++ b/nova/templates/deployment-conductor.yaml @@ -37,12 +37,11 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_nova_conductor_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.conductor.node_selector_key }}: {{ .Values.labels.conductor.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_nova_conductor_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: nova-conductor image: {{ .Values.images.conductor }} diff --git a/nova/templates/deployment-consoleauth.yaml b/nova/templates/deployment-consoleauth.yaml index e205dda3b0..11274d2124 100644 --- a/nova/templates/deployment-consoleauth.yaml +++ b/nova/templates/deployment-consoleauth.yaml @@ -38,12 +38,11 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_nova_consoleauth_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.consoleauth.node_selector_key }}: {{ .Values.labels.consoleauth.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_nova_consoleauth_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: nova-consoleauth image: {{ .Values.images.consoleauth }} diff --git a/nova/templates/deployment-scheduler.yaml b/nova/templates/deployment-scheduler.yaml index dedca5e979..4e2efd8d18 100644 --- a/nova/templates/deployment-scheduler.yaml +++ b/nova/templates/deployment-scheduler.yaml @@ -38,12 +38,11 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_nova_scheduler_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.scheduler.node_selector_key }}: {{ .Values.labels.scheduler.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_nova_scheduler_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: nova-scheduler image: {{ .Values.images.scheduler }} diff --git a/nova/templates/job-bootstrap.yaml b/nova/templates/job-bootstrap.yaml index 90c2d881ef..4b10e5db56 100644 --- a/nova/templates/job-bootstrap.yaml +++ b/nova/templates/job-bootstrap.yaml @@ -23,15 +23,12 @@ metadata: name: nova-bootstrap spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_nova_bootstrap_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_nova_bootstrap_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: nova-bootstrap image: {{ .Values.images.bootstrap }} diff --git a/nova/templates/job-db-init.yaml b/nova/templates/job-db-init.yaml index 902c37c5a1..f01c2ca7b6 100644 --- a/nova/templates/job-db-init.yaml +++ b/nova/templates/job-db-init.yaml @@ -20,15 +20,12 @@ metadata: name: nova-db-init spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: nova-db-init image: {{ .Values.images.db_init }} diff --git a/nova/templates/job-db-sync.yaml b/nova/templates/job-db-sync.yaml index 6fc8f63ac7..0af5d389e0 100644 --- a/nova/templates/job-db-sync.yaml +++ b/nova/templates/job-db-sync.yaml @@ -20,15 +20,12 @@ metadata: name: nova-db-sync spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: nova-db-sync image: {{ .Values.images.db_sync }} diff --git a/nova/templates/job-ks-endpoints.yaml b/nova/templates/job-ks-endpoints.yaml index a2dc46ec04..69f5aa7d85 100644 --- a/nova/templates/job-ks-endpoints.yaml +++ b/nova/templates/job-ks-endpoints.yaml @@ -21,15 +21,12 @@ metadata: name: nova-ks-endpoints spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "compute" }} {{- range $key2, $osServiceEndPoint := tuple "admin" "internal" "public" }} diff --git a/nova/templates/job-ks-service.yaml b/nova/templates/job-ks-service.yaml index 92bd8b15d9..d8314d5158 100644 --- a/nova/templates/job-ks-service.yaml +++ b/nova/templates/job-ks-service.yaml @@ -21,15 +21,12 @@ metadata: name: nova-ks-service spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "compute" }} - name: {{ $osServiceType }}-ks-service-registration diff --git a/nova/templates/job-ks-user.yaml b/nova/templates/job-ks-user.yaml index 7c948bd2b5..badc6df7dd 100644 --- a/nova/templates/job-ks-user.yaml +++ b/nova/templates/job-ks-user.yaml @@ -22,15 +22,12 @@ metadata: name: nova-ks-user spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: nova-ks-user image: {{ .Values.images.ks_user }} diff --git a/rabbitmq/templates/deployment.yaml b/rabbitmq/templates/deployment.yaml index df7ca55938..86c3b1d878 100644 --- a/rabbitmq/templates/deployment.yaml +++ b/rabbitmq/templates/deployment.yaml @@ -35,9 +35,6 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' # TODO: this needs to be moved to common. scheduler.alpha.kubernetes.io/affinity: > { @@ -67,6 +64,8 @@ spec: - name: rabbitmq-etc configMap: name: rabbitmq-etc + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 9 }} containers: - name: rabbitmq image: {{ .Values.images.rabbitmq }} diff --git a/senlin/templates/deployment-api.yaml b/senlin/templates/deployment-api.yaml index a81d79bb00..340d1fe300 100644 --- a/senlin/templates/deployment-api.yaml +++ b/senlin/templates/deployment-api.yaml @@ -37,13 +37,12 @@ spec: annotations: configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_senlin_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} terminationGracePeriodSeconds: {{ .Values.termination_grace_period.api.timeout | default "30" }} + initContainers: +{{ tuple $envAll $dependencies $mounts_senlin_api_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: senlin-api image: {{ .Values.images.api }} diff --git a/senlin/templates/job-db-init.yaml b/senlin/templates/job-db-init.yaml index b308b7d88b..7067e9991f 100644 --- a/senlin/templates/job-db-init.yaml +++ b/senlin/templates/job-db-init.yaml @@ -20,15 +20,12 @@ metadata: name: senlin-db-init spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: senlin-db-init image: {{ .Values.images.db_init | quote }} diff --git a/senlin/templates/job-db-sync.yaml b/senlin/templates/job-db-sync.yaml index 9a76832f81..618c4a0698 100644 --- a/senlin/templates/job-db-sync.yaml +++ b/senlin/templates/job-db-sync.yaml @@ -20,15 +20,12 @@ metadata: name: senlin-db-sync spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: senlin-db-sync image: {{ .Values.images.db_sync }} diff --git a/senlin/templates/job-ks-endpoints.yaml b/senlin/templates/job-ks-endpoints.yaml index db06ef8860..a8df38aea0 100644 --- a/senlin/templates/job-ks-endpoints.yaml +++ b/senlin/templates/job-ks-endpoints.yaml @@ -21,15 +21,12 @@ metadata: name: senlin-ks-endpoints spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "clustering" }} {{- range $key2, $osServiceEndPoint := tuple "admin" "internal" "public" }} diff --git a/senlin/templates/job-ks-service.yaml b/senlin/templates/job-ks-service.yaml index f31ffb71c9..43a60d13f8 100644 --- a/senlin/templates/job-ks-service.yaml +++ b/senlin/templates/job-ks-service.yaml @@ -21,15 +21,12 @@ metadata: name: senlin-ks-service spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: {{- range $key1, $osServiceType := tuple "clustering" }} - name: {{ $osServiceType }}-ks-service-registration diff --git a/senlin/templates/job-ks-user.yaml b/senlin/templates/job-ks-user.yaml index c700114a75..4f22fa30cc 100644 --- a/senlin/templates/job-ks-user.yaml +++ b/senlin/templates/job-ks-user.yaml @@ -22,15 +22,12 @@ metadata: name: senlin-ks-user spec: template: - metadata: - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: restartPolicy: OnFailure nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies "[]" | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: senlin-ks-user image: {{ .Values.images.ks_user }} diff --git a/senlin/templates/statefulset-engine.yaml b/senlin/templates/statefulset-engine.yaml index d975c21492..75d81be703 100644 --- a/senlin/templates/statefulset-engine.yaml +++ b/senlin/templates/statefulset-engine.yaml @@ -27,13 +27,11 @@ spec: metadata: labels: app: senlin-engine - annotations: - pod.beta.kubernetes.io/init-containers: '[ -{{ tuple $envAll $dependencies $mounts_senlin_engine_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 10 }} - ]' spec: nodeSelector: {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + initContainers: +{{ tuple $envAll $dependencies $mounts_senlin_engine_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: - name: senlin-engine image: {{ .Values.images.engine }}