From 319fd2cbec96e237e9f6539637a8b4e50f938c89 Mon Sep 17 00:00:00 2001 From: portdirect Date: Wed, 7 Feb 2018 10:15:21 -0500 Subject: [PATCH] Jobs: Apply uniform node selector label to all jobs in OSH This PS applies a uniform node selector label to all jobs in OSH. Change-Id: I2efedcea2085b8189bd0bd12dd0ee66e63db0d97 --- barbican/templates/job-ks-user.yaml | 2 +- barbican/values.yaml | 3 +++ ceph/templates/job-bootstrap.yaml | 2 +- ceph/templates/job-cephfs-client-key.yaml | 2 +- ceph/templates/job-keyring.yaml | 2 +- ceph/templates/job-ks-endpoints.yaml | 2 +- ceph/templates/job-ks-service.yaml | 2 +- ceph/templates/job-ks-user.yaml | 2 +- .../job-namespace-client-key-cleaner.yaml | 2 +- ceph/templates/job-namespace-client-key.yaml | 2 +- ceph/templates/job-rbd-pool.yaml | 4 ++-- ceph/templates/job-storage-admin-keys.yaml | 2 +- ceph/values.yaml | 2 +- cinder/templates/job-backup-storage-init.yaml | 2 +- cinder/templates/job-bootstrap.yaml | 2 +- cinder/templates/job-clean.yaml | 2 ++ cinder/templates/job-db-drop.yaml | 2 +- cinder/templates/job-db-init.yaml | 2 +- cinder/templates/job-db-sync.yaml | 2 +- cinder/templates/job-ks-endpoints.yaml | 2 +- cinder/templates/job-ks-service.yaml | 2 +- cinder/templates/job-ks-user.yaml | 2 +- cinder/values.yaml | 3 +++ congress/templates/job-db-init.yaml | 2 +- congress/templates/job-db-sync.yaml | 2 +- congress/templates/job-ds-create.yaml | 2 +- congress/templates/job-ks-endpoints.yaml | 2 +- congress/templates/job-ks-service.yaml | 2 +- congress/templates/job-ks-user.yaml | 2 +- congress/values.yaml | 19 +++++++++++++++++++ glance/templates/job-bootstrap.yaml | 2 +- glance/templates/job-clean.yaml | 2 ++ glance/templates/job-db-drop.yaml | 2 +- glance/templates/job-db-init.yaml | 2 +- glance/templates/job-db-sync.yaml | 2 +- glance/templates/job-ks-endpoints.yaml | 2 +- glance/templates/job-ks-service.yaml | 2 +- glance/templates/job-ks-user.yaml | 2 +- glance/templates/job-storage-init.yaml | 2 +- glance/values.yaml | 3 +++ gnocchi/templates/job-clean.yaml | 2 ++ gnocchi/templates/job-db-init-indexer.yaml | 2 +- gnocchi/templates/job-db-init.yaml | 2 +- gnocchi/templates/job-db-sync.yaml | 2 +- gnocchi/templates/job-ks-endpoints.yaml | 2 +- gnocchi/templates/job-ks-service.yaml | 2 +- gnocchi/templates/job-ks-user.yaml | 2 +- gnocchi/templates/job-storage-init.yaml | 2 +- gnocchi/values.yaml | 3 +++ heat/templates/job-bootstrap.yaml | 2 +- heat/templates/job-db-drop.yaml | 2 +- heat/templates/job-db-init.yaml | 2 +- heat/templates/job-db-sync.yaml | 2 +- heat/templates/job-ks-endpoints.yaml | 2 +- heat/templates/job-ks-service.yaml | 2 +- heat/templates/job-ks-user-domain.yaml | 2 +- heat/templates/job-ks-user-trustee.yaml | 2 +- heat/templates/job-ks-user.yaml | 2 +- heat/templates/job-trusts.yaml | 2 +- heat/values.yaml | 3 +++ magnum/templates/job-bootstrap.yaml | 2 +- magnum/templates/job-db-drop.yaml | 2 +- magnum/templates/job-db-init.yaml | 2 +- magnum/templates/job-db-sync.yaml | 2 +- magnum/templates/job-ks-endpoints.yaml | 2 +- magnum/templates/job-ks-service.yaml | 2 +- magnum/templates/job-ks-user.yaml | 2 +- magnum/values.yaml | 3 +++ mistral/templates/job-bootstrap.yaml | 2 +- mistral/templates/job-db-drop.yaml | 2 +- mistral/templates/job-db-init.yaml | 2 +- mistral/templates/job-db-sync.yaml | 2 +- mistral/templates/job-ks-endpoints.yaml | 2 +- mistral/templates/job-ks-service.yaml | 2 +- mistral/templates/job-ks-user.yaml | 2 +- mistral/values.yaml | 3 +++ neutron/templates/job-bootstrap.yaml | 2 +- neutron/templates/job-db-drop.yaml | 2 +- neutron/templates/job-db-init.yaml | 2 +- neutron/templates/job-db-sync.yaml | 2 +- neutron/templates/job-ks-endpoints.yaml | 2 +- neutron/templates/job-ks-service.yaml | 2 +- neutron/templates/job-ks-user.yaml | 2 +- neutron/values.yaml | 3 +++ rally/templates/job-bootstrap.yaml | 2 +- rally/templates/job-db-init.yaml | 2 +- rally/templates/job-ks-endpoints.yaml | 2 +- rally/templates/job-ks-service.yaml | 2 +- rally/templates/job-ks-user.yaml | 2 +- rally/templates/job-manage-db.yaml | 2 +- rally/templates/job-run-task.yaml | 2 +- rally/values.yaml | 3 +++ senlin/templates/job-bootstrap.yaml | 2 +- senlin/templates/job-db-drop.yaml | 2 +- senlin/templates/job-db-init.yaml | 2 +- senlin/templates/job-db-sync.yaml | 2 +- senlin/templates/job-ks-endpoints.yaml | 2 +- senlin/templates/job-ks-service.yaml | 2 +- senlin/templates/job-ks-user.yaml | 2 +- senlin/values.yaml | 3 +++ 100 files changed, 142 insertions(+), 87 deletions(-) diff --git a/barbican/templates/job-ks-user.yaml b/barbican/templates/job-ks-user.yaml index 9c260d4f3b..b333b76fd8 100644 --- a/barbican/templates/job-ks-user.yaml +++ b/barbican/templates/job-ks-user.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if .Values.manifests.job_ks_user }} -{{- $nodeSelector := dict .Values.labels.node_selector_key .Values.labels.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "barbican-bin" "serviceName" "barbican" "serviceUser" "barbican" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/barbican/values.yaml b/barbican/values.yaml index 70ae4d004b..1f6e2c2b67 100644 --- a/barbican/values.yaml +++ b/barbican/values.yaml @@ -11,6 +11,9 @@ # limitations under the License. labels: + job: + node_selector_key: openstack-control-plane + node_selector_value: enabled node_selector_key: openstack-control-plane node_selector_value: enabled diff --git a/ceph/templates/job-bootstrap.yaml b/ceph/templates/job-bootstrap.yaml index 4e7c6ec66d..b788539231 100644 --- a/ceph/templates/job-bootstrap.yaml +++ b/ceph/templates/job-bootstrap.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.jobs.node_selector_key }}: {{ .Values.labels.jobs.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/ceph/templates/job-cephfs-client-key.yaml b/ceph/templates/job-cephfs-client-key.yaml index c1e43ddc98..1ad56bf6b8 100644 --- a/ceph/templates/job-cephfs-client-key.yaml +++ b/ceph/templates/job-cephfs-client-key.yaml @@ -92,7 +92,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ $envAll.Values.labels.jobs.node_selector_key }}: {{ $envAll.Values.labels.jobs.node_selector_value }} + {{ $envAll.Values.labels.job.node_selector_key }}: {{ $envAll.Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/ceph/templates/job-keyring.yaml b/ceph/templates/job-keyring.yaml index 9faa9a43f3..089250fe07 100644 --- a/ceph/templates/job-keyring.yaml +++ b/ceph/templates/job-keyring.yaml @@ -65,7 +65,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ $envAll.Values.labels.jobs.node_selector_key }}: {{ $envAll.Values.labels.jobs.node_selector_value }} + {{ $envAll.Values.labels.job.node_selector_key }}: {{ $envAll.Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/ceph/templates/job-ks-endpoints.yaml b/ceph/templates/job-ks-endpoints.yaml index 675a83041a..60b9d855f8 100644 --- a/ceph/templates/job-ks-endpoints.yaml +++ b/ceph/templates/job-ks-endpoints.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ $envAll.Values.labels.jobs.node_selector_key }}: {{ $envAll.Values.labels.jobs.node_selector_value }} + {{ $envAll.Values.labels.job.node_selector_key }}: {{ $envAll.Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/ceph/templates/job-ks-service.yaml b/ceph/templates/job-ks-service.yaml index a4d72f4db7..c32323c7a5 100644 --- a/ceph/templates/job-ks-service.yaml +++ b/ceph/templates/job-ks-service.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ $envAll.Values.labels.jobs.node_selector_key }}: {{ $envAll.Values.labels.jobs.node_selector_value }} + {{ $envAll.Values.labels.job.node_selector_key }}: {{ $envAll.Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/ceph/templates/job-ks-user.yaml b/ceph/templates/job-ks-user.yaml index 00e779af8b..184c46d846 100644 --- a/ceph/templates/job-ks-user.yaml +++ b/ceph/templates/job-ks-user.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if and .Values.manifests.job_ks_user .Values.deployment.rgw_keystone_user_and_endpoints }} -{{- $nodeSelector := dict .Values.labels.jobs.node_selector_key .Values.labels.jobs.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "ceph-bin-ks" "serviceName" "ceph" "serviceUser" "swift" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/ceph/templates/job-namespace-client-key-cleaner.yaml b/ceph/templates/job-namespace-client-key-cleaner.yaml index 439c9c3f4f..9fd3d373f6 100644 --- a/ceph/templates/job-namespace-client-key-cleaner.yaml +++ b/ceph/templates/job-namespace-client-key-cleaner.yaml @@ -69,7 +69,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ $envAll.Values.labels.jobs.node_selector_key }}: {{ $envAll.Values.labels.jobs.node_selector_value }} + {{ $envAll.Values.labels.job.node_selector_key }}: {{ $envAll.Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/ceph/templates/job-namespace-client-key.yaml b/ceph/templates/job-namespace-client-key.yaml index 4f35712ec1..871ad7a08c 100644 --- a/ceph/templates/job-namespace-client-key.yaml +++ b/ceph/templates/job-namespace-client-key.yaml @@ -92,7 +92,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ $envAll.Values.labels.jobs.node_selector_key }}: {{ $envAll.Values.labels.jobs.node_selector_value }} + {{ $envAll.Values.labels.job.node_selector_key }}: {{ $envAll.Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/ceph/templates/job-rbd-pool.yaml b/ceph/templates/job-rbd-pool.yaml index 50699ebdbf..cefb0f8b1e 100644 --- a/ceph/templates/job-rbd-pool.yaml +++ b/ceph/templates/job-rbd-pool.yaml @@ -35,9 +35,9 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure affinity: -{{ tuple $envAll "ceph" "mgr" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }} +{{ tuple $envAll "ceph" "rbd-pool" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }} nodeSelector: - {{ .Values.labels.mgr.node_selector_key }}: {{ .Values.labels.mgr.node_selector_value }} + {{ $envAll.Values.labels.job.node_selector_key }}: {{ $envAll.Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/ceph/templates/job-storage-admin-keys.yaml b/ceph/templates/job-storage-admin-keys.yaml index d1bbee6c37..b0d46db447 100644 --- a/ceph/templates/job-storage-admin-keys.yaml +++ b/ceph/templates/job-storage-admin-keys.yaml @@ -61,7 +61,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ $envAll.Values.labels.jobs.node_selector_key }}: {{ $envAll.Values.labels.jobs.node_selector_value }} + {{ $envAll.Values.labels.job.node_selector_key }}: {{ $envAll.Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/ceph/values.yaml b/ceph/values.yaml index d3e348cbe0..64d9500091 100644 --- a/ceph/values.yaml +++ b/ceph/values.yaml @@ -34,7 +34,7 @@ images: pull_policy: "IfNotPresent" labels: - jobs: + job: node_selector_key: openstack-control-plane node_selector_value: enabled provisioner: diff --git a/cinder/templates/job-backup-storage-init.yaml b/cinder/templates/job-backup-storage-init.yaml index ebd94bdd62..d1bdac328c 100644 --- a/cinder/templates/job-backup-storage-init.yaml +++ b/cinder/templates/job-backup-storage-init.yaml @@ -62,7 +62,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} {{- if eq .Values.conf.cinder.DEFAULT.backup_driver "cinder.backup.drivers.ceph" }} diff --git a/cinder/templates/job-bootstrap.yaml b/cinder/templates/job-bootstrap.yaml index a8742220ce..0893a975ef 100644 --- a/cinder/templates/job-bootstrap.yaml +++ b/cinder/templates/job-bootstrap.yaml @@ -35,7 +35,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/cinder/templates/job-clean.yaml b/cinder/templates/job-clean.yaml index b2b688ab35..7beec5d5f6 100644 --- a/cinder/templates/job-clean.yaml +++ b/cinder/templates/job-clean.yaml @@ -71,6 +71,8 @@ spec: spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure + nodeSelector: + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/cinder/templates/job-db-drop.yaml b/cinder/templates/job-db-drop.yaml index 4ce58dab5d..ea629dfd7d 100644 --- a/cinder/templates/job-db-drop.yaml +++ b/cinder/templates/job-db-drop.yaml @@ -39,7 +39,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/cinder/templates/job-db-init.yaml b/cinder/templates/job-db-init.yaml index 8fab3c9aa9..5a38ff81c9 100644 --- a/cinder/templates/job-db-init.yaml +++ b/cinder/templates/job-db-init.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/cinder/templates/job-db-sync.yaml b/cinder/templates/job-db-sync.yaml index 74e55d24d2..bb063cd581 100644 --- a/cinder/templates/job-db-sync.yaml +++ b/cinder/templates/job-db-sync.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/cinder/templates/job-ks-endpoints.yaml b/cinder/templates/job-ks-endpoints.yaml index 35dceb1142..9e3f6b5732 100644 --- a/cinder/templates/job-ks-endpoints.yaml +++ b/cinder/templates/job-ks-endpoints.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/cinder/templates/job-ks-service.yaml b/cinder/templates/job-ks-service.yaml index fb5bcfe64d..be4d27cb4c 100644 --- a/cinder/templates/job-ks-service.yaml +++ b/cinder/templates/job-ks-service.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/cinder/templates/job-ks-user.yaml b/cinder/templates/job-ks-user.yaml index 63e03b36ca..a3a0348587 100644 --- a/cinder/templates/job-ks-user.yaml +++ b/cinder/templates/job-ks-user.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if .Values.manifests.job_ks_user }} -{{- $nodeSelector := dict .Values.labels.node_selector_key .Values.labels.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "cinder-bin" "serviceName" "cinder" "serviceUser" "cinder" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/cinder/values.yaml b/cinder/values.yaml index f76897ac4a..e2a525ce60 100644 --- a/cinder/values.yaml +++ b/cinder/values.yaml @@ -22,6 +22,9 @@ storage: ceph labels: node_selector_key: openstack-control-plane node_selector_value: enabled + job: + node_selector_key: openstack-control-plane + node_selector_value: enabled release_group: null diff --git a/congress/templates/job-db-init.yaml b/congress/templates/job-db-init.yaml index 96428df296..66b782ac98 100644 --- a/congress/templates/job-db-init.yaml +++ b/congress/templates/job-db-init.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/congress/templates/job-db-sync.yaml b/congress/templates/job-db-sync.yaml index 05717eff58..4e0ad5e482 100644 --- a/congress/templates/job-db-sync.yaml +++ b/congress/templates/job-db-sync.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/congress/templates/job-ds-create.yaml b/congress/templates/job-ds-create.yaml index 3adfec3b91..26cea83a3d 100644 --- a/congress/templates/job-ds-create.yaml +++ b/congress/templates/job-ds-create.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/congress/templates/job-ks-endpoints.yaml b/congress/templates/job-ks-endpoints.yaml index 2920dbd71a..f64a6cd86b 100644 --- a/congress/templates/job-ks-endpoints.yaml +++ b/congress/templates/job-ks-endpoints.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/congress/templates/job-ks-service.yaml b/congress/templates/job-ks-service.yaml index 22195f7be5..ea90a62156 100644 --- a/congress/templates/job-ks-service.yaml +++ b/congress/templates/job-ks-service.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/congress/templates/job-ks-user.yaml b/congress/templates/job-ks-user.yaml index b2644a54a2..04eea44ce1 100644 --- a/congress/templates/job-ks-user.yaml +++ b/congress/templates/job-ks-user.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if .Values.manifests.job_ks_user }} -{{- $nodeSelector := dict .Values.labels.node_selector_key .Values.labels.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "congress-bin" "serviceName" "congress" "serviceUser" "congress" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/congress/values.yaml b/congress/values.yaml index 6174eeadcd..e0d17e646f 100644 --- a/congress/values.yaml +++ b/congress/values.yaml @@ -1,6 +1,25 @@ +# Copyright 2017 The Openstack-Helm Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Default values for congress. + labels: node_selector_key: openstack-control-plane node_selector_value: enabled + job: + node_selector_key: openstack-control-plane + node_selector_value: enabled release_group: null diff --git a/glance/templates/job-bootstrap.yaml b/glance/templates/job-bootstrap.yaml index 1df8b0216f..593e56ae27 100644 --- a/glance/templates/job-bootstrap.yaml +++ b/glance/templates/job-bootstrap.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/glance/templates/job-clean.yaml b/glance/templates/job-clean.yaml index 962854bca8..b2b9120b5c 100644 --- a/glance/templates/job-clean.yaml +++ b/glance/templates/job-clean.yaml @@ -71,6 +71,8 @@ spec: spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure + nodeSelector: + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/glance/templates/job-db-drop.yaml b/glance/templates/job-db-drop.yaml index c305211639..8de41277d4 100644 --- a/glance/templates/job-db-drop.yaml +++ b/glance/templates/job-db-drop.yaml @@ -39,7 +39,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/glance/templates/job-db-init.yaml b/glance/templates/job-db-init.yaml index 2ad9b25623..c188654b23 100644 --- a/glance/templates/job-db-init.yaml +++ b/glance/templates/job-db-init.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/glance/templates/job-db-sync.yaml b/glance/templates/job-db-sync.yaml index 63e1bb91a2..6bee009675 100644 --- a/glance/templates/job-db-sync.yaml +++ b/glance/templates/job-db-sync.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/glance/templates/job-ks-endpoints.yaml b/glance/templates/job-ks-endpoints.yaml index e794c5db02..53c3c9f68a 100644 --- a/glance/templates/job-ks-endpoints.yaml +++ b/glance/templates/job-ks-endpoints.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/glance/templates/job-ks-service.yaml b/glance/templates/job-ks-service.yaml index 0e887a69ad..4163a67f23 100644 --- a/glance/templates/job-ks-service.yaml +++ b/glance/templates/job-ks-service.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/glance/templates/job-ks-user.yaml b/glance/templates/job-ks-user.yaml index a2d665c0dd..2c6b024dc5 100644 --- a/glance/templates/job-ks-user.yaml +++ b/glance/templates/job-ks-user.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if .Values.manifests.job_ks_user }} -{{- $nodeSelector := dict .Values.labels.node_selector_key .Values.labels.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "glance-bin" "serviceName" "glance" "serviceUser" "glance" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/glance/templates/job-storage-init.yaml b/glance/templates/job-storage-init.yaml index 1445554b3d..db4e827df5 100644 --- a/glance/templates/job-storage-init.yaml +++ b/glance/templates/job-storage-init.yaml @@ -62,7 +62,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} {{ if or (eq .Values.storage "rbd") (eq .Values.storage "radosgw") }} diff --git a/glance/values.yaml b/glance/values.yaml index 7e5328fafb..ddb485d9ec 100644 --- a/glance/values.yaml +++ b/glance/values.yaml @@ -23,6 +23,9 @@ storage: radosgw labels: node_selector_key: openstack-control-plane node_selector_value: enabled + job: + node_selector_key: openstack-control-plane + node_selector_value: enabled release_group: null diff --git a/gnocchi/templates/job-clean.yaml b/gnocchi/templates/job-clean.yaml index c50d6f6bb8..5e35ab2467 100644 --- a/gnocchi/templates/job-clean.yaml +++ b/gnocchi/templates/job-clean.yaml @@ -70,6 +70,8 @@ spec: spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure + nodeSelector: + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/gnocchi/templates/job-db-init-indexer.yaml b/gnocchi/templates/job-db-init-indexer.yaml index 80e56984cb..daa03e01d0 100644 --- a/gnocchi/templates/job-db-init-indexer.yaml +++ b/gnocchi/templates/job-db-init-indexer.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/gnocchi/templates/job-db-init.yaml b/gnocchi/templates/job-db-init.yaml index 87d65c3110..719e7006f1 100644 --- a/gnocchi/templates/job-db-init.yaml +++ b/gnocchi/templates/job-db-init.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/gnocchi/templates/job-db-sync.yaml b/gnocchi/templates/job-db-sync.yaml index 7811799bfe..6540c5e3bf 100644 --- a/gnocchi/templates/job-db-sync.yaml +++ b/gnocchi/templates/job-db-sync.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} - name: ceph-keyring-placement diff --git a/gnocchi/templates/job-ks-endpoints.yaml b/gnocchi/templates/job-ks-endpoints.yaml index 075a28491b..44c31b1a1b 100644 --- a/gnocchi/templates/job-ks-endpoints.yaml +++ b/gnocchi/templates/job-ks-endpoints.yaml @@ -36,7 +36,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/gnocchi/templates/job-ks-service.yaml b/gnocchi/templates/job-ks-service.yaml index be4804c98f..691040aa2f 100644 --- a/gnocchi/templates/job-ks-service.yaml +++ b/gnocchi/templates/job-ks-service.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/gnocchi/templates/job-ks-user.yaml b/gnocchi/templates/job-ks-user.yaml index dd764ea7be..804cf9a306 100644 --- a/gnocchi/templates/job-ks-user.yaml +++ b/gnocchi/templates/job-ks-user.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if .Values.manifests.job_ks_user }} -{{- $nodeSelector := dict .Values.labels.node_selector_key .Values.labels.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "gnocchi-bin" "serviceName" "gnocchi" "serviceUser" "gnocchi" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/gnocchi/templates/job-storage-init.yaml b/gnocchi/templates/job-storage-init.yaml index c75b074439..449bd8e469 100644 --- a/gnocchi/templates/job-storage-init.yaml +++ b/gnocchi/templates/job-storage-init.yaml @@ -62,7 +62,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} - name: ceph-keyring-placement diff --git a/gnocchi/values.yaml b/gnocchi/values.yaml index dc8e704256..c3abdc22a7 100644 --- a/gnocchi/values.yaml +++ b/gnocchi/values.yaml @@ -5,6 +5,9 @@ labels: node_selector_key: openstack-control-plane node_selector_value: enabled + job: + node_selector_key: openstack-control-plane + node_selector_value: enabled images: tags: diff --git a/heat/templates/job-bootstrap.yaml b/heat/templates/job-bootstrap.yaml index 7387209d0f..d6f8abc398 100644 --- a/heat/templates/job-bootstrap.yaml +++ b/heat/templates/job-bootstrap.yaml @@ -38,7 +38,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies $mounts_heat_bootstrap_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/heat/templates/job-db-drop.yaml b/heat/templates/job-db-drop.yaml index 31d5aaa0e1..6b22e1283b 100644 --- a/heat/templates/job-db-drop.yaml +++ b/heat/templates/job-db-drop.yaml @@ -39,7 +39,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/heat/templates/job-db-init.yaml b/heat/templates/job-db-init.yaml index 1efbddaede..663a9b0143 100644 --- a/heat/templates/job-db-init.yaml +++ b/heat/templates/job-db-init.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/heat/templates/job-db-sync.yaml b/heat/templates/job-db-sync.yaml index dfe0178fb9..3c00b571fd 100644 --- a/heat/templates/job-db-sync.yaml +++ b/heat/templates/job-db-sync.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/heat/templates/job-ks-endpoints.yaml b/heat/templates/job-ks-endpoints.yaml index 5fe664917b..ea1f09b46d 100644 --- a/heat/templates/job-ks-endpoints.yaml +++ b/heat/templates/job-ks-endpoints.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/heat/templates/job-ks-service.yaml b/heat/templates/job-ks-service.yaml index 033b22438a..375a45a57d 100644 --- a/heat/templates/job-ks-service.yaml +++ b/heat/templates/job-ks-service.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/heat/templates/job-ks-user-domain.yaml b/heat/templates/job-ks-user-domain.yaml index 691b8fc45d..4228d05903 100644 --- a/heat/templates/job-ks-user-domain.yaml +++ b/heat/templates/job-ks-user-domain.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/heat/templates/job-ks-user-trustee.yaml b/heat/templates/job-ks-user-trustee.yaml index 176c6e8a86..1741bbd7db 100644 --- a/heat/templates/job-ks-user-trustee.yaml +++ b/heat/templates/job-ks-user-trustee.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if .Values.manifests.job_ks_user_trustee }} -{{- $nodeSelector := dict .Values.labels.node_selector_key .Values.labels.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "heat-bin" "serviceName" "heat" "serviceUser" "heat_trustee" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/heat/templates/job-ks-user.yaml b/heat/templates/job-ks-user.yaml index 8985a52918..5a057a1a0f 100644 --- a/heat/templates/job-ks-user.yaml +++ b/heat/templates/job-ks-user.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if .Values.manifests.job_ks_user }} -{{- $nodeSelector := dict .Values.labels.node_selector_key .Values.labels.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "heat-bin" "serviceName" "heat" "serviceUser" "heat" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/heat/templates/job-trusts.yaml b/heat/templates/job-trusts.yaml index 667fd9b4e5..c31c4f5ece 100644 --- a/heat/templates/job-trusts.yaml +++ b/heat/templates/job-trusts.yaml @@ -36,7 +36,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies $mounts_heat_trusts_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/heat/values.yaml b/heat/values.yaml index c1cb3ee2a7..7d076e6a15 100644 --- a/heat/values.yaml +++ b/heat/values.yaml @@ -22,6 +22,9 @@ release_group: null labels: node_selector_key: openstack-control-plane node_selector_value: enabled + job: + node_selector_key: openstack-control-plane + node_selector_value: enabled images: tags: diff --git a/magnum/templates/job-bootstrap.yaml b/magnum/templates/job-bootstrap.yaml index ad1b15031c..d01bafb095 100644 --- a/magnum/templates/job-bootstrap.yaml +++ b/magnum/templates/job-bootstrap.yaml @@ -38,7 +38,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies $mounts_magnum_bootstrap_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/magnum/templates/job-db-drop.yaml b/magnum/templates/job-db-drop.yaml index a57ec70563..f581099c7d 100644 --- a/magnum/templates/job-db-drop.yaml +++ b/magnum/templates/job-db-drop.yaml @@ -39,7 +39,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/magnum/templates/job-db-init.yaml b/magnum/templates/job-db-init.yaml index 27df7911f5..75a4b54bba 100644 --- a/magnum/templates/job-db-init.yaml +++ b/magnum/templates/job-db-init.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/magnum/templates/job-db-sync.yaml b/magnum/templates/job-db-sync.yaml index b02678de00..3cb6dacb57 100644 --- a/magnum/templates/job-db-sync.yaml +++ b/magnum/templates/job-db-sync.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/magnum/templates/job-ks-endpoints.yaml b/magnum/templates/job-ks-endpoints.yaml index 733c298853..2746688269 100644 --- a/magnum/templates/job-ks-endpoints.yaml +++ b/magnum/templates/job-ks-endpoints.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/magnum/templates/job-ks-service.yaml b/magnum/templates/job-ks-service.yaml index 17eeb45fd7..570cdba577 100644 --- a/magnum/templates/job-ks-service.yaml +++ b/magnum/templates/job-ks-service.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/magnum/templates/job-ks-user.yaml b/magnum/templates/job-ks-user.yaml index d04fca28ae..a091a0a757 100644 --- a/magnum/templates/job-ks-user.yaml +++ b/magnum/templates/job-ks-user.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if .Values.manifests.job_ks_user }} -{{- $nodeSelector := dict .Values.labels.node_selector_key .Values.labels.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "magnum-bin" "serviceName" "magnum" "serviceUser" "magnum" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/magnum/values.yaml b/magnum/values.yaml index 876ec294a9..4ab5b305e0 100644 --- a/magnum/values.yaml +++ b/magnum/values.yaml @@ -22,6 +22,9 @@ release_group: null labels: node_selector_key: openstack-control-plane node_selector_value: enabled + job: + node_selector_key: openstack-control-plane + node_selector_value: enabled images: tags: diff --git a/mistral/templates/job-bootstrap.yaml b/mistral/templates/job-bootstrap.yaml index e1814a8ba9..15d20da04c 100644 --- a/mistral/templates/job-bootstrap.yaml +++ b/mistral/templates/job-bootstrap.yaml @@ -37,7 +37,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies $mounts_mistral_bootstrap_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/mistral/templates/job-db-drop.yaml b/mistral/templates/job-db-drop.yaml index 990a0c4a10..2286771082 100644 --- a/mistral/templates/job-db-drop.yaml +++ b/mistral/templates/job-db-drop.yaml @@ -39,7 +39,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/mistral/templates/job-db-init.yaml b/mistral/templates/job-db-init.yaml index 209c41b233..1effc448ce 100644 --- a/mistral/templates/job-db-init.yaml +++ b/mistral/templates/job-db-init.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/mistral/templates/job-db-sync.yaml b/mistral/templates/job-db-sync.yaml index 08ed82bff1..002cd8e506 100644 --- a/mistral/templates/job-db-sync.yaml +++ b/mistral/templates/job-db-sync.yaml @@ -35,7 +35,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/mistral/templates/job-ks-endpoints.yaml b/mistral/templates/job-ks-endpoints.yaml index e96275ae00..e931b377bd 100644 --- a/mistral/templates/job-ks-endpoints.yaml +++ b/mistral/templates/job-ks-endpoints.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/mistral/templates/job-ks-service.yaml b/mistral/templates/job-ks-service.yaml index c4e792b22a..cdafb2ce9f 100644 --- a/mistral/templates/job-ks-service.yaml +++ b/mistral/templates/job-ks-service.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/mistral/templates/job-ks-user.yaml b/mistral/templates/job-ks-user.yaml index 63c1a920a0..389114a686 100644 --- a/mistral/templates/job-ks-user.yaml +++ b/mistral/templates/job-ks-user.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if .Values.manifests.job_ks_user }} -{{- $nodeSelector := dict .Values.labels.node_selector_key .Values.labels.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "mistral-bin" "serviceName" "mistral" "serviceUser" "mistral" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/mistral/values.yaml b/mistral/values.yaml index 8ff6097348..def3e1bd5e 100644 --- a/mistral/values.yaml +++ b/mistral/values.yaml @@ -20,6 +20,9 @@ labels: node_selector_key: openstack-control-plane node_selector_value: enabled + job: + node_selector_key: openstack-control-plane + node_selector_value: enabled release_group: null diff --git a/neutron/templates/job-bootstrap.yaml b/neutron/templates/job-bootstrap.yaml index 034cd2a65f..9bbda9d44c 100644 --- a/neutron/templates/job-bootstrap.yaml +++ b/neutron/templates/job-bootstrap.yaml @@ -38,7 +38,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies $mounts_neutron_bootstrap_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/neutron/templates/job-db-drop.yaml b/neutron/templates/job-db-drop.yaml index e43b8c6842..f91d07abc1 100644 --- a/neutron/templates/job-db-drop.yaml +++ b/neutron/templates/job-db-drop.yaml @@ -40,7 +40,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/neutron/templates/job-db-init.yaml b/neutron/templates/job-db-init.yaml index f802edac02..59a53bfb34 100644 --- a/neutron/templates/job-db-init.yaml +++ b/neutron/templates/job-db-init.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/neutron/templates/job-db-sync.yaml b/neutron/templates/job-db-sync.yaml index 675cba9d39..0b4ff26c8d 100644 --- a/neutron/templates/job-db-sync.yaml +++ b/neutron/templates/job-db-sync.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/neutron/templates/job-ks-endpoints.yaml b/neutron/templates/job-ks-endpoints.yaml index 9eaee7fea7..fc3ffe55da 100644 --- a/neutron/templates/job-ks-endpoints.yaml +++ b/neutron/templates/job-ks-endpoints.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/neutron/templates/job-ks-service.yaml b/neutron/templates/job-ks-service.yaml index e9897cdd02..80aa89b19e 100644 --- a/neutron/templates/job-ks-service.yaml +++ b/neutron/templates/job-ks-service.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/neutron/templates/job-ks-user.yaml b/neutron/templates/job-ks-user.yaml index 9f119eb525..48236ade3d 100644 --- a/neutron/templates/job-ks-user.yaml +++ b/neutron/templates/job-ks-user.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if .Values.manifests.job_ks_user }} -{{- $nodeSelector := dict .Values.labels.server.node_selector_key .Values.labels.server.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "neutron-bin" "serviceName" "neutron" "serviceUser" "neutron" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/neutron/values.yaml b/neutron/values.yaml index 1049e2491c..c6dad342ae 100644 --- a/neutron/values.yaml +++ b/neutron/values.yaml @@ -62,6 +62,9 @@ labels: server: node_selector_key: openstack-control-plane node_selector_value: enabled + job: + node_selector_key: openstack-control-plane + node_selector_value: enabled network: # provide what type of network wiring will be used diff --git a/rally/templates/job-bootstrap.yaml b/rally/templates/job-bootstrap.yaml index 0d09511dea..c9962e57d4 100644 --- a/rally/templates/job-bootstrap.yaml +++ b/rally/templates/job-bootstrap.yaml @@ -38,7 +38,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies $mounts_rally_bootstrap_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/rally/templates/job-db-init.yaml b/rally/templates/job-db-init.yaml index 42b915d336..a63e9b6af8 100644 --- a/rally/templates/job-db-init.yaml +++ b/rally/templates/job-db-init.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/rally/templates/job-ks-endpoints.yaml b/rally/templates/job-ks-endpoints.yaml index a035e2179a..c98c89a772 100644 --- a/rally/templates/job-ks-endpoints.yaml +++ b/rally/templates/job-ks-endpoints.yaml @@ -33,7 +33,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/rally/templates/job-ks-service.yaml b/rally/templates/job-ks-service.yaml index 5c36490c4d..281c025d84 100644 --- a/rally/templates/job-ks-service.yaml +++ b/rally/templates/job-ks-service.yaml @@ -33,7 +33,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/rally/templates/job-ks-user.yaml b/rally/templates/job-ks-user.yaml index f16eaec433..ee3029d5f9 100644 --- a/rally/templates/job-ks-user.yaml +++ b/rally/templates/job-ks-user.yaml @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */}} -{{- $nodeSelector := dict .Values.labels.node_selector_key .Values.labels.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "rally-bin" "serviceName" "rally" "serviceUser" "rally" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/rally/templates/job-manage-db.yaml b/rally/templates/job-manage-db.yaml index 5cc7456c38..9c2d5bfe12 100644 --- a/rally/templates/job-manage-db.yaml +++ b/rally/templates/job-manage-db.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/rally/templates/job-run-task.yaml b/rally/templates/job-run-task.yaml index 3b472a9084..86fac5b23f 100644 --- a/rally/templates/job-run-task.yaml +++ b/rally/templates/job-run-task.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} - name: rally-run-task-init diff --git a/rally/values.yaml b/rally/values.yaml index 832c7ac363..84b6d5732f 100644 --- a/rally/values.yaml +++ b/rally/values.yaml @@ -15,6 +15,9 @@ labels: node_selector_key: openstack-control-plane node_selector_value: enabled + job: + node_selector_key: openstack-control-plane + node_selector_value: enabled images: tags: diff --git a/senlin/templates/job-bootstrap.yaml b/senlin/templates/job-bootstrap.yaml index 0630b46779..c2e9d28cde 100644 --- a/senlin/templates/job-bootstrap.yaml +++ b/senlin/templates/job-bootstrap.yaml @@ -37,7 +37,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies $mounts_senlin_bootstrap_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/senlin/templates/job-db-drop.yaml b/senlin/templates/job-db-drop.yaml index 1172e42576..e220b673c5 100644 --- a/senlin/templates/job-db-drop.yaml +++ b/senlin/templates/job-db-drop.yaml @@ -39,7 +39,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/senlin/templates/job-db-init.yaml b/senlin/templates/job-db-init.yaml index daf6d377e1..3a55c5c09d 100644 --- a/senlin/templates/job-db-init.yaml +++ b/senlin/templates/job-db-init.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/senlin/templates/job-db-sync.yaml b/senlin/templates/job-db-sync.yaml index bc94b7bc57..6e8a9ba4db 100644 --- a/senlin/templates/job-db-sync.yaml +++ b/senlin/templates/job-db-sync.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/senlin/templates/job-ks-endpoints.yaml b/senlin/templates/job-ks-endpoints.yaml index 5f283c4bcd..1403523210 100644 --- a/senlin/templates/job-ks-endpoints.yaml +++ b/senlin/templates/job-ks-endpoints.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/senlin/templates/job-ks-service.yaml b/senlin/templates/job-ks-service.yaml index 6fa2b257c0..2d605e2e09 100644 --- a/senlin/templates/job-ks-service.yaml +++ b/senlin/templates/job-ks-service.yaml @@ -34,7 +34,7 @@ spec: serviceAccountName: {{ $serviceAccountName }} restartPolicy: OnFailure nodeSelector: - {{ .Values.labels.node_selector_key }}: {{ .Values.labels.node_selector_value }} + {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: {{ tuple $envAll $dependencies list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} containers: diff --git a/senlin/templates/job-ks-user.yaml b/senlin/templates/job-ks-user.yaml index 8444bae002..4c64ba3f36 100644 --- a/senlin/templates/job-ks-user.yaml +++ b/senlin/templates/job-ks-user.yaml @@ -15,7 +15,7 @@ limitations under the License. */}} {{- if .Values.manifests.job_ks_user }} -{{- $nodeSelector := dict .Values.labels.node_selector_key .Values.labels.node_selector_value }} +{{- $nodeSelector := dict .Values.labels.job.node_selector_key .Values.labels.job.node_selector_value }} {{- $dependencies := .Values.dependencies.ks_user }} {{- $ksUserJob := dict "envAll" . "nodeSelector" $nodeSelector "dependencies" $dependencies "configMapBin" "senlin-bin" "serviceName" "senlin" "serviceUser" "senlin" }} {{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }} diff --git a/senlin/values.yaml b/senlin/values.yaml index 02c69fbcbb..d793fd6385 100644 --- a/senlin/values.yaml +++ b/senlin/values.yaml @@ -20,6 +20,9 @@ labels: node_selector_key: openstack-control-plane node_selector_value: enabled + job: + node_selector_key: openstack-control-plane + node_selector_value: enabled release_group: null