diff --git a/ingress/Chart.yaml b/ingress/Chart.yaml index 7daaeda29..4282462a1 100644 --- a/ingress/Chart.yaml +++ b/ingress/Chart.yaml @@ -15,7 +15,7 @@ apiVersion: v1 appVersion: v0.42.0 description: OpenStack-Helm Ingress Controller name: ingress -version: 0.2.6 +version: 0.2.7 home: https://github.com/kubernetes/ingress sources: - https://github.com/kubernetes/ingress diff --git a/ingress/templates/deployment-error.yaml b/ingress/templates/deployment-error.yaml index 417e63d4f..ccd6c3b33 100644 --- a/ingress/templates/deployment-error.yaml +++ b/ingress/templates/deployment-error.yaml @@ -49,6 +49,9 @@ spec: {{ tuple $envAll "ingress" "error-pages" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }} nodeSelector: {{ .Values.labels.error_server.node_selector_key }}: {{ .Values.labels.error_server.node_selector_value | quote }} +{{ if $envAll.Values.pod.tolerations.ingress.enabled }} +{{ tuple $envAll "ingress" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }} +{{ end }} terminationGracePeriodSeconds: {{ .Values.pod.lifecycle.termination_grace_period.error_pages.timeout | default "60" }} initContainers: {{ tuple $envAll "error_pages" list | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} diff --git a/ingress/templates/deployment-ingress.yaml b/ingress/templates/deployment-ingress.yaml index c6aaf46a7..780af3a32 100644 --- a/ingress/templates/deployment-ingress.yaml +++ b/ingress/templates/deployment-ingress.yaml @@ -206,6 +206,9 @@ spec: affinity: {{ tuple $envAll "ingress" "server" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }} {{- end }} +{{ if $envAll.Values.pod.tolerations.ingress.enabled }} +{{ tuple $envAll "ingress" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }} +{{ end }} nodeSelector: {{ .Values.labels.server.node_selector_key }}: {{ .Values.labels.server.node_selector_value | quote }} {{- if .Values.network.host_namespace }} diff --git a/ingress/templates/job-image-repo-sync.yaml b/ingress/templates/job-image-repo-sync.yaml index c4841467d..2132f9a3f 100644 --- a/ingress/templates/job-image-repo-sync.yaml +++ b/ingress/templates/job-image-repo-sync.yaml @@ -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" "ingress" -}} +{{- if .Values.pod.tolerations.ingress.enabled -}} +{{- $_ := set $imageRepoSyncJob "tolerationsEnabled" true -}} +{{- end -}} {{ $imageRepoSyncJob | include "helm-toolkit.manifests.job_image_repo_sync" }} {{- end }} diff --git a/ingress/values.yaml b/ingress/values.yaml index 18003ba82..2a25cda2f 100644 --- a/ingress/values.yaml +++ b/ingress/values.yaml @@ -81,6 +81,13 @@ pod: default: kubernetes.io/hostname weight: default: 10 + tolerations: + ingress: + enabled: false + tolerations: + - key: node-role.kubernetes.io/master + operator: Exists + effect: NoSchedule dns_policy: "ClusterFirstWithHostNet" replicas: ingress: 1 diff --git a/releasenotes/notes/ingress.yaml b/releasenotes/notes/ingress.yaml index 277227dfa..a51d1e316 100644 --- a/releasenotes/notes/ingress.yaml +++ b/releasenotes/notes/ingress.yaml @@ -10,4 +10,5 @@ ingress: - 0.2.4 Update htk requirements - 0.2.5 Migrate Ingress resources to networking.k8s.io/v1 - 0.2.6 Add option to assign VIP as externalIP + - 0.2.7 Enable taint toleration for Openstack services jobs ...