Skip to content

Commit 3a64e7f

Browse files
ericpaulsenethanndickson
authored andcommitted
helm: add topologySpreadConstraints value
1 parent bcd68ee commit 3a64e7f

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

helm/coder/values.yaml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ coder:
4747
# if not set. If you're using the chart directly from git, the default
4848
# app version will not work and you'll need to set this value. The helm
4949
# chart helpfully fails quickly in this case.
50-
tag: ""
50+
tag: "v2.15.0"
5151
# coder.image.pullPolicy -- The pull policy to use for the image. See:
5252
# https://kubernetes.io/docs/concepts/containers/images/#image-pull-policy
5353
pullPolicy: IfNotPresent
@@ -236,6 +236,15 @@ coder:
236236
topologyKey: kubernetes.io/hostname
237237
weight: 1
238238

239+
# coder.topologySpreadConstraints -- Topology spread constraints for the Coder pod.
240+
topologySpreadConstraints:
241+
- maxSkew: 1
242+
topologyKey: kubernetes.io/hostname
243+
whenUnsatisfiable: DoNotSchedule
244+
labelSelector:
245+
matchLabels:
246+
app: coder
247+
239248
# coder.tolerations -- Tolerations for tainted nodes.
240249
# See: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
241250
tolerations:

helm/libcoder/templates/_coder.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,10 @@ spec:
4343
nodeSelector:
4444
{{ toYaml . | nindent 8 }}
4545
{{- end }}
46+
{{- with .Values.coder.topologySpreadConstraints }}
47+
topologySpreadConstraints:
48+
{{- toYaml .Values.coder.topologySpreadConstraints | nindent 8 }}
49+
{{- end }}
4650
{{- with .Values.coder.initContainers }}
4751
initContainers:
4852
{{ toYaml . | nindent 8 }}

0 commit comments

Comments
 (0)