mirror of
https://github.com/coder/coder.git
synced 2025-07-09 11:45:56 +00:00
helm: add affinity, nodeSelectors, tolerations (#4763)
This commit is contained in:
@ -30,9 +30,21 @@ spec:
|
|||||||
restartPolicy: Always
|
restartPolicy: Always
|
||||||
{{- with .Values.coder.image.pullSecrets }}
|
{{- with .Values.coder.image.pullSecrets }}
|
||||||
imagePullSecrets:
|
imagePullSecrets:
|
||||||
{{- toYaml . | nindent 8 }}
|
{{- toYaml . | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
terminationGracePeriodSeconds: 60
|
terminationGracePeriodSeconds: 60
|
||||||
|
{{- with .Values.coder.affinity }}
|
||||||
|
affinity:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- with .Values.coder.tolerations }}
|
||||||
|
tolerations:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- with .Values.coder.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{ toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
containers:
|
containers:
|
||||||
- name: coder
|
- name: coder
|
||||||
image: {{ include "coder.image" . | quote }}
|
image: {{ include "coder.image" . | quote }}
|
||||||
|
@ -65,8 +65,7 @@ coder:
|
|||||||
|
|
||||||
# coder.resources -- The resources to request for Coder. These are optional
|
# coder.resources -- The resources to request for Coder. These are optional
|
||||||
# and are not set by default.
|
# and are not set by default.
|
||||||
resources:
|
resources: {}
|
||||||
{}
|
|
||||||
# limits:
|
# limits:
|
||||||
# cpu: 100m
|
# cpu: 100m
|
||||||
# memory: 128Mi
|
# memory: 128Mi
|
||||||
@ -74,6 +73,35 @@ coder:
|
|||||||
# cpu: 100m
|
# cpu: 100m
|
||||||
# memory: 128Mi
|
# memory: 128Mi
|
||||||
|
|
||||||
|
# coder.affinity -- Allows specifying an affinity rule for the `coder` deployment.
|
||||||
|
# The default rule prefers to schedule coder pods on different
|
||||||
|
# nodes, which is only applicable if coder.replicaCount is greater than 1.
|
||||||
|
affinity:
|
||||||
|
podAntiAffinity:
|
||||||
|
preferredDuringSchedulingIgnoredDuringExecution:
|
||||||
|
- podAffinityTerm:
|
||||||
|
labelSelector:
|
||||||
|
matchExpressions:
|
||||||
|
- key: app.coder.com
|
||||||
|
operator: In
|
||||||
|
values:
|
||||||
|
- "true"
|
||||||
|
topologyKey: kubernetes.io/hostname
|
||||||
|
weight: 1
|
||||||
|
|
||||||
|
# coder.tolerations -- Tolerations for tainted nodes.
|
||||||
|
# See: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
|
||||||
|
tolerations: {}
|
||||||
|
# - key: "key"
|
||||||
|
# operator: "Equal"
|
||||||
|
# value: "value"
|
||||||
|
# effect: "NoSchedule"
|
||||||
|
|
||||||
|
# coder.nodeSelector -- Node labels for constraining coder pods to nodes.
|
||||||
|
# See: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#nodeselector
|
||||||
|
nodeSelector: {}
|
||||||
|
# kubernetes.io/os: linux
|
||||||
|
|
||||||
# coder.service -- The Service object to expose for Coder.
|
# coder.service -- The Service object to expose for Coder.
|
||||||
service:
|
service:
|
||||||
# coder.service.enable -- Whether to create the Service object.
|
# coder.service.enable -- Whether to create the Service object.
|
||||||
|
Reference in New Issue
Block a user