Skip to content

Commit

Permalink
Include labelSelector and matchLabelKeys for topologySpreadConstraints
Browse files Browse the repository at this point in the history
  • Loading branch information
Patrick Vickery authored and Patrick Vickery committed Aug 8, 2024
1 parent 1ceaf79 commit 651a289
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
2 changes: 1 addition & 1 deletion charts/external-dns/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: external-dns
description: ExternalDNS synchronizes exposed Kubernetes Services and Ingresses with DNS providers.
type: application
version: 1.14.5
version: 1.14.6
appVersion: 0.14.2
keywords:
- kubernetes
Expand Down
13 changes: 12 additions & 1 deletion charts/external-dns/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,18 @@ spec:
{{- end }}
{{- with .Values.topologySpreadConstraints }}
topologySpreadConstraints:
{{- toYaml . | nindent 8 }}
{{- range . }}
- {{ toYaml . | nindent 10 | trim }}
{{- if not (hasKey . "labelSelector") }}
labelSelector:
matchLabels:
{{- include "external-dns.selectorLabels" $ | nindent 12 }}
{{- end }}
{{- if not (hasKey . "matchLabelKeys") }}
matchLabelKeys:
- pod-template-hash
{{- end }}
{{- end }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
Expand Down

0 comments on commit 651a289

Please sign in to comment.