feat(argo-rollouts): Add support for topologySpreadConstraints (#1755)

This commit is contained in:
Kiyoshi Muranaka 2023-01-18 11:38:50 +09:00 committed by GitHub
parent 5c6ad38b15
commit 2777121707
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 48 additions and 2 deletions

View file

@ -83,6 +83,18 @@ spec:
affinity:
{{- toYaml .Values.controller.affinity | nindent 8 }}
{{- end }}
{{- with .Values.controller.topologySpreadConstraints }}
topologySpreadConstraints:
{{- range $constraint := . }}
- {{ toYaml $constraint | nindent 8 | trim }}
{{- if not $constraint.labelSelector }}
labelSelector:
matchLabels:
app.kubernetes.io/component: {{ $.Values.controller.component }}
{{- include "argo-rollouts.selectorLabels" $ | nindent 12 }}
{{- end }}
{{- end }}
{{- end }}
{{- with .Values.controller.priorityClassName }}
priorityClassName: {{ . }}
{{- end }}