Enable taint toleration for memcached

This adds taint toleration support for openstack jobs

Signed-off-by: Lucas Cavalcante <lucasmedeiros.cavalcante@windriver.com>
Change-Id: If0e02fe8df0bef5065ab99f71263b55f03ab5c3a
This commit is contained in:
Thiago Brito 2022-03-22 15:12:33 -03:00
parent 1f894e9004
commit 010664e87e
5 changed files with 15 additions and 1 deletions

View File

@ -15,6 +15,6 @@ apiVersion: v1
appVersion: v1.5.5
description: OpenStack-Helm Memcached
name: memcached
version: 0.1.7
version: 0.1.8
home: https://github.com/memcached/memcached
...

View File

@ -50,6 +50,9 @@ spec:
{{ tuple $envAll "memcached" "server" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }}
nodeSelector:
{{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value | quote }}
{{ if $envAll.Values.pod.tolerations.memcached.enabled }}
{{ tuple $envAll "memcached" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }}
{{ end }}
terminationGracePeriodSeconds: {{ .Values.pod.lifecycle.termination_grace_period.memcached.timeout | default "30" }}
initContainers:
{{ tuple $envAll "memcached" list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }}

View File

@ -14,5 +14,8 @@ limitations under the License.
{{- if and .Values.manifests.job_image_repo_sync .Values.images.local_registry.active }}
{{- $imageRepoSyncJob := dict "envAll" . "serviceName" "memcached" -}}
{{- if .Values.pod.tolerations.memcached.enabled -}}
{{- $_ := set $imageRepoSyncJob "tolerationsEnabled" true -}}
{{- end -}}
{{ $imageRepoSyncJob | include "helm-toolkit.manifests.job_image_repo_sync" }}
{{- end }}

View File

@ -142,6 +142,13 @@ pod:
default: preferredDuringSchedulingIgnoredDuringExecution
weight:
default: 10
tolerations:
memcached:
enabled: false
tolerations:
- key: node-role.kubernetes.io/master
operator: Exists
effect: NoSchedule
lifecycle:
upgrades:
deployments:

View File

@ -8,4 +8,5 @@ memcached:
- 0.1.5 Update htk requirements
- 0.1.6 Switch to using sidecar for exporter
- 0.1.7 Updated naming for subchart compatibility
- 0.1.8 Enable taint toleration for Openstack services jobs
...