feat(argo-cd): Add support for topologySpreadConstraints (#917)
* feat(argo-cd): Add support for topologySpreadConstraints Signed-off-by: Sander van Schie <sandervanschie@gmail.com> * Apply suggestions from code review Signed-off-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com> Co-authored-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>
This commit is contained in:
parent
91aaaf066f
commit
804cd4ec54
8 changed files with 102 additions and 2 deletions
|
|
@ -79,6 +79,17 @@ spec:
|
|||
affinity:
|
||||
{{- toYaml .Values.redis.affinity | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.redis.topologySpreadConstraints }}
|
||||
topologySpreadConstraints:
|
||||
{{- range $constraint := . }}
|
||||
- {{ toYaml $constraint | nindent 8 | trim }}
|
||||
{{- if not $constraint.labelSelector }}
|
||||
labelSelector:
|
||||
matchLabels:
|
||||
app.kubernetes.io/name: {{ include "argo-cd.name" $ }}-{{ $.Values.redis.name }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.redis.volumes }}
|
||||
volumes:
|
||||
{{- toYaml .Values.redis.volumes | nindent 8}}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue