Enable taint toleration for cinder
This changes use the helm-toolkit template for toleration in openstack services Signed-off-by: Lucas Cavalcante <lucasmedeiros.cavalcante@windriver.com> Story: 2009276 Task: 43531 Depends-On: I168837f962465d1c89acc511b7bf4064ac4b546c Change-Id: Id63d0950fd8b7ff9592cbfe196b95739dc0b1380
This commit is contained in:
parent
151c03d5ec
commit
a9987be64c
@ -14,7 +14,7 @@ apiVersion: v1
|
||||
appVersion: v1.0.0
|
||||
description: OpenStack-Helm Cinder
|
||||
name: cinder
|
||||
version: 0.2.15
|
||||
version: 0.2.16
|
||||
home: https://docs.openstack.org/cinder/latest/
|
||||
icon: https://www.openstack.org/themes/openstack/images/project-mascots/Cinder/OpenStack_Project_Cinder_vertical.png
|
||||
sources:
|
||||
|
@ -52,6 +52,9 @@ spec:
|
||||
{{ dict "envAll" $envAll "application" "volume_usage_audit" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 10 }}
|
||||
serviceAccountName: {{ $serviceAccountName }}
|
||||
restartPolicy: OnFailure
|
||||
{{ if $envAll.Values.pod.tolerations.cinder.enabled }}
|
||||
{{ tuple $envAll "cinder" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 10 }}
|
||||
{{ end }}
|
||||
nodeSelector:
|
||||
{{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }}
|
||||
initContainers:
|
||||
|
@ -49,6 +49,9 @@ spec:
|
||||
{{ dict "envAll" $envAll "application" "cinder_api" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }}
|
||||
affinity:
|
||||
{{ tuple $envAll "cinder" "api" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }}
|
||||
{{ if $envAll.Values.pod.tolerations.cinder.enabled }}
|
||||
{{ tuple $envAll "cinder" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }}
|
||||
{{ end }}
|
||||
nodeSelector:
|
||||
{{ .Values.labels.api.node_selector_key }}: {{ .Values.labels.api.node_selector_value }}
|
||||
terminationGracePeriodSeconds: {{ .Values.pod.lifecycle.termination_grace_period.api.timeout | default "30" }}
|
||||
|
@ -51,6 +51,9 @@ spec:
|
||||
{{ dict "envAll" $envAll "application" "cinder_backup" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }}
|
||||
affinity:
|
||||
{{ tuple $envAll "cinder" "backup" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }}
|
||||
{{ if $envAll.Values.pod.tolerations.cinder.enabled }}
|
||||
{{ tuple $envAll "cinder" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }}
|
||||
{{ end }}
|
||||
nodeSelector:
|
||||
{{ .Values.labels.backup.node_selector_key }}: {{ .Values.labels.backup.node_selector_value }}
|
||||
{{- if .Values.pod.useHostNetwork.backup }}
|
||||
|
@ -49,6 +49,9 @@ spec:
|
||||
{{ dict "envAll" $envAll "application" "cinder_scheduler" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }}
|
||||
affinity:
|
||||
{{ tuple $envAll "cinder" "scheduler" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }}
|
||||
{{ if $envAll.Values.pod.tolerations.cinder.enabled }}
|
||||
{{ tuple $envAll "cinder" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }}
|
||||
{{ end }}
|
||||
nodeSelector:
|
||||
{{ .Values.labels.scheduler.node_selector_key }}: {{ .Values.labels.scheduler.node_selector_value }}
|
||||
initContainers:
|
||||
|
@ -51,6 +51,9 @@ spec:
|
||||
{{ dict "envAll" $envAll "application" "cinder_volume" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }}
|
||||
affinity:
|
||||
{{ tuple $envAll "cinder" "volume" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }}
|
||||
{{ if $envAll.Values.pod.tolerations.cinder.enabled }}
|
||||
{{ tuple $envAll "cinder" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }}
|
||||
{{ end }}
|
||||
nodeSelector:
|
||||
{{ .Values.labels.volume.node_selector_key }}: {{ .Values.labels.volume.node_selector_value }}
|
||||
{{- if .Values.pod.useHostNetwork.volume }}
|
||||
|
@ -65,6 +65,9 @@ spec:
|
||||
serviceAccountName: {{ $serviceAccountName }}
|
||||
{{ dict "envAll" $envAll "application" "storage_init" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }}
|
||||
restartPolicy: OnFailure
|
||||
{{ if $envAll.Values.pod.tolerations.cinder.enabled }}
|
||||
{{ tuple $envAll "cinder" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }}
|
||||
{{ end }}
|
||||
nodeSelector:
|
||||
{{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }}
|
||||
initContainers:
|
||||
|
@ -17,5 +17,8 @@ limitations under the License.
|
||||
{{- if .Values.manifests.certificates -}}
|
||||
{{- $_ := set $bootstrapJob "tlsSecret" .Values.secrets.tls.volumev3.api.internal -}}
|
||||
{{- end -}}
|
||||
{{- if .Values.pod.tolerations.cinder.enabled -}}
|
||||
{{- $_ := set $bootstrapJob "tolerationsEnabled" true -}}
|
||||
{{- end -}}
|
||||
{{ $bootstrapJob | include "helm-toolkit.manifests.job_bootstrap" }}
|
||||
{{- end }}
|
||||
|
@ -64,6 +64,9 @@ spec:
|
||||
serviceAccountName: {{ $serviceAccountName }}
|
||||
{{ dict "envAll" $envAll "application" "clean" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }}
|
||||
restartPolicy: OnFailure
|
||||
{{ if $envAll.Values.pod.tolerations.cinder.enabled }}
|
||||
{{ tuple $envAll "cinder" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }}
|
||||
{{ end }}
|
||||
nodeSelector:
|
||||
{{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }}
|
||||
initContainers:
|
||||
|
@ -46,6 +46,9 @@ spec:
|
||||
{{ dict "envAll" $envAll "application" "create_internal_tenant" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }}
|
||||
serviceAccountName: {{ $serviceAccountName | quote }}
|
||||
restartPolicy: OnFailure
|
||||
{{ if $envAll.Values.pod.tolerations.cinder.enabled }}
|
||||
{{ tuple $envAll "cinder" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }}
|
||||
{{ end }}
|
||||
nodeSelector:
|
||||
{{ toYaml $nodeSelector | indent 8 }}
|
||||
initContainers:
|
||||
|
@ -17,5 +17,8 @@ limitations under the License.
|
||||
{{- if .Values.manifests.certificates -}}
|
||||
{{- $_ := set $dbDropJob "dbAdminTlsSecret" .Values.endpoints.oslo_db.auth.admin.secret.tls.internal -}}
|
||||
{{- end -}}
|
||||
{{- if .Values.pod.tolerations.cinder.enabled -}}
|
||||
{{- $_ := set $dbDropJob "tolerationsEnabled" true -}}
|
||||
{{- end -}}
|
||||
{{ $dbDropJob | include "helm-toolkit.manifests.job_db_drop_mysql" }}
|
||||
{{- end }}
|
||||
|
@ -25,5 +25,8 @@ helm.sh/hook-weight: "-5"
|
||||
{{- if .Values.helm3_hook }}
|
||||
{{- $_ := set $dbInitJob "jobAnnotations" (include "metadata.annotations.job.db_init" . | fromYaml) }}
|
||||
{{- end }}
|
||||
{{- if .Values.pod.tolerations.cinder.enabled -}}
|
||||
{{- $_ := set $dbInitJob "tolerationsEnabled" true -}}
|
||||
{{- end -}}
|
||||
{{ $dbInitJob | include "helm-toolkit.manifests.job_db_init_mysql" }}
|
||||
{{- end }}
|
||||
|
@ -25,5 +25,8 @@ helm.sh/hook-weight: "-4"
|
||||
{{- if .Values.helm3_hook }}
|
||||
{{- $_ := set $dbSyncJob "jobAnnotations" (include "metadata.annotations.job.db_sync" . | fromYaml) }}
|
||||
{{- end }}
|
||||
{{- if .Values.pod.tolerations.cinder.enabled -}}
|
||||
{{- $_ := set $dbSyncJob "tolerationsEnabled" true -}}
|
||||
{{- end -}}
|
||||
{{ $dbSyncJob | include "helm-toolkit.manifests.job_db_sync" }}
|
||||
{{- end }}
|
||||
|
@ -21,5 +21,8 @@ helm.sh/hook: post-install,post-upgrade
|
||||
{{- if .Values.helm3_hook }}
|
||||
{{- $_ := $imageRepoSyncJob "jobAnnotations" (include "metadata.annotations.job.repo_sync" . | fromYaml) }}
|
||||
{{- end }}
|
||||
{{- if .Values.pod.tolerations.cinder.enabled -}}
|
||||
{{- $_ := set $imageRepoSyncJob "tolerationsEnabled" true -}}
|
||||
{{- end -}}
|
||||
{{ $imageRepoSyncJob | include "helm-toolkit.manifests.job_image_repo_sync" }}
|
||||
{{- end }}
|
||||
|
@ -25,5 +25,8 @@ helm.sh/hook-weight: "-2"
|
||||
{{- if .Values.helm3_hook }}
|
||||
{{- $_ := set $ksServiceJob "jobAnnotations" (include "metadata.annotations.job.ks_endpoints" . | fromYaml) }}
|
||||
{{- end }}
|
||||
{{- if .Values.pod.tolerations.cinder.enabled -}}
|
||||
{{- $_ := set $ksServiceJob "tolerationsEnabled" true -}}
|
||||
{{- end -}}
|
||||
{{ $ksServiceJob | include "helm-toolkit.manifests.job_ks_endpoints" }}
|
||||
{{- end }}
|
||||
|
@ -25,5 +25,8 @@ helm.sh/hook-weight: "-3"
|
||||
{{- if .Values.helm3_hook }}
|
||||
{{- $_ := set $ksServiceJob "jobAnnotations" (include "metadata.annotations.job.ks_service" . | fromYaml) }}
|
||||
{{- end }}
|
||||
{{- if .Values.pod.tolerations.cinder.enabled -}}
|
||||
{{- $_ := set $ksServiceJob "tolerationsEnabled" true -}}
|
||||
{{- end -}}
|
||||
{{ $ksServiceJob | include "helm-toolkit.manifests.job_ks_service" }}
|
||||
{{- end }}
|
||||
|
@ -25,5 +25,8 @@ helm.sh/hook-weight: "-1"
|
||||
{{- if .Values.helm3_hook }}
|
||||
{{- $_ := set $ksUserJob "jobAnnotations" (include "metadata.annotations.job.ks_user" . | fromYaml) }}
|
||||
{{- end }}
|
||||
{{- if .Values.pod.tolerations.cinder.enabled -}}
|
||||
{{- $_ := set $ksUserJob "tolerationsEnabled" true -}}
|
||||
{{- end -}}
|
||||
{{ $ksUserJob | include "helm-toolkit.manifests.job_ks_user" }}
|
||||
{{- end }}
|
||||
|
@ -25,5 +25,8 @@ helm.sh/hook-weight: "-4"
|
||||
{{- if .Values.helm3_hook }}
|
||||
{{- $_ := set $rmqUserJob "jobAnnotations" (include "metadata.annotations.job.rabbit_init" . | fromYaml) }}
|
||||
{{- end }}
|
||||
{{- if .Values.pod.tolerations.cinder.enabled -}}
|
||||
{{- $_ := set $rmqUserJob "tolerationsEnabled" true -}}
|
||||
{{- end -}}
|
||||
{{ $rmqUserJob | include "helm-toolkit.manifests.job_rabbit_init" }}
|
||||
{{- end }}
|
||||
|
@ -63,6 +63,9 @@ spec:
|
||||
serviceAccountName: {{ $serviceAccountName }}
|
||||
{{ dict "envAll" $envAll "application" "cinder" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }}
|
||||
restartPolicy: OnFailure
|
||||
{{ if $envAll.Values.pod.tolerations.cinder.enabled }}
|
||||
{{ tuple $envAll "cinder" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }}
|
||||
{{ end }}
|
||||
nodeSelector:
|
||||
{{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }}
|
||||
initContainers:
|
||||
|
@ -33,6 +33,9 @@ metadata:
|
||||
{{ dict "envAll" $envAll "podName" "cinder-test" "containerNames" (list "init" "cinder-test" "cinder-test-ks-user") | include "helm-toolkit.snippets.kubernetes_mandatory_access_control_annotation" | indent 4 }}
|
||||
spec:
|
||||
restartPolicy: Never
|
||||
{{ if $envAll.Values.pod.tolerations.cinder.enabled }}
|
||||
{{ tuple $envAll "cinder" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 2 }}
|
||||
{{ end }}
|
||||
nodeSelector:
|
||||
{{ .Values.labels.test.node_selector_key }}: {{ .Values.labels.test.node_selector_value }}
|
||||
serviceAccountName: {{ $serviceAccountName }}
|
||||
|
@ -173,6 +173,13 @@ pod:
|
||||
default: kubernetes.io/hostname
|
||||
weight:
|
||||
default: 10
|
||||
tolerations:
|
||||
cinder:
|
||||
enabled: false
|
||||
tolerations:
|
||||
- key: node-role.kubernetes.io/master
|
||||
operator: Exists
|
||||
effect: NoSchedule
|
||||
useHostNetwork:
|
||||
volume: false
|
||||
backup: false
|
||||
|
@ -32,4 +32,5 @@ cinder:
|
||||
- 0.2.13 Upgrade default images to ussuri
|
||||
- 0.2.14 Fix notifications
|
||||
- 0.2.15 Remove glance registry
|
||||
- 0.2.16 Enable taint toleration for Openstack services
|
||||
...
|
||||
|
Loading…
Reference in New Issue
Block a user