Skip to content

Commit d221a00

Browse files
committed
Add crdjob-specific Affinity, Tolerations and NodeSelector (fixes #318)
Signed-off-by: Dinko Korunic <[email protected]>
1 parent a1f6446 commit d221a00

File tree

2 files changed

+19
-3
lines changed

2 files changed

+19
-3
lines changed

kubernetes-ingress/templates/controller-crdjob.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,15 +98,15 @@ spec:
9898
resources:
9999
{{- toYaml .Values.controller.resources | nindent 12 }}
100100
{{- end }}
101-
{{- with .Values.controller.nodeSelector }}
101+
{{- with .Values.crdjob.nodeSelector }}
102102
nodeSelector:
103103
{{- toYaml . | nindent 8 }}
104104
{{- end }}
105-
{{- with .Values.controller.affinity }}
105+
{{- with .Values.crdjob.affinity }}
106106
affinity:
107107
{{- toYaml . | nindent 8 }}
108108
{{- end }}
109-
{{- with .Values.controller.tolerations }}
109+
{{- with .Values.crdjob.tolerations }}
110110
tolerations:
111111
{{- toYaml . | nindent 8 }}
112112
{{- end }}

kubernetes-ingress/values.yaml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -639,3 +639,19 @@ crdjob:
639639
## Automatic job cleanup
640640
## ref: https://kubernetes.io/docs/concepts/workloads/controllers/ttlafterfinished/
641641
ttlSecondsAfterFinished: 600
642+
643+
## Pod Node assignment
644+
## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/
645+
nodeSelector: {}
646+
647+
## Node Taints and Tolerations for pod-node cheduling through attraction/repelling
648+
## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
649+
tolerations: []
650+
# - key: "key"
651+
# operator: "Equal|Exists"
652+
# value: "value"
653+
# effect: "NoSchedule|PreferNoSchedule|NoExecute(1.6 only)"
654+
655+
## Node Affinity for pod-node scheduling constraints
656+
## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity
657+
affinity: {}

0 commit comments

Comments
 (0)