Skip to content

Commit 108920c

Browse files
egabancholindhe
authored andcommitted
values: add nodeSelector and tolerations
1 parent 29f53c5 commit 108920c

File tree

4 files changed

+54
-0
lines changed

4 files changed

+54
-0
lines changed

charts/invenio/templates/web-deployment.yaml

+8
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,14 @@ spec:
1717
app.kubernetes.io/component: web
1818
spec:
1919
terminationGracePeriodSeconds: {{ .Values.web.terminationGracePeriodSeconds }}
20+
{{- with .Values.web.nodeSelector }}
21+
nodeSelector:
22+
{{- tpl (toYaml .) $ | nindent 8 -}}
23+
{{- end }}
24+
{{- with .Values.web.tolerations }}
25+
tolerations:
26+
{{- tpl (toYaml .) $ | nindent 8 -}}
27+
{{- end }}
2028
containers:
2129
- name: web
2230
image: {{ required "Missing .Values.web.image" .Values.web.image }}

charts/invenio/templates/worker-beat-deployment.yaml

+8
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,14 @@ spec:
1616
labels:
1717
app.kubernetes.io/component: worker-beat
1818
spec:
19+
{{- with .Values.workerBeat.nodeSelector }}
20+
nodeSelector:
21+
{{- tpl (toYaml .) $ | nindent 8 -}}
22+
{{- end }}
23+
{{- with .Values.workerBeat.tolerations }}
24+
tolerations:
25+
{{- tpl (toYaml .) $ | nindent 8 -}}
26+
{{- end }}
1927
containers:
2028
- name: worker-beat
2129
image: {{ required "Missing .Values.worker.image" .Values.worker.image }}

charts/invenio/templates/worker-deployment.yaml

+8
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,14 @@ spec:
1616
labels:
1717
app.kubernetes.io/component: worker
1818
spec:
19+
{{- with .Values.worker.nodeSelector }}
20+
nodeSelector:
21+
{{- tpl (toYaml .) $ | nindent 8 -}}
22+
{{- end }}
23+
{{- with .Values.worker.tolerations }}
24+
tolerations:
25+
{{- tpl (toYaml .) $ | nindent 8 -}}
26+
{{- end }}
1927
containers:
2028
- name: worker
2129
image: {{ required "Missing .Values.worker.image" .Values.worker.image }}

charts/invenio/values.yaml

+30
Original file line numberDiff line numberDiff line change
@@ -223,8 +223,22 @@ web:
223223
capabilities:
224224
drop:
225225
- ALL
226+
## @param web.annotations Add extra annotations to the web pods
227+
##
226228
annotations: []
229+
## @param web.nodeSelector Node labels for web pods assignment
230+
## Ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/
231+
##
232+
nodeSelector: {}
233+
## @param web.tolerations Tolerations for web pods assignment
234+
## Ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
235+
##
236+
tolerations: []
237+
## Invenio web service parameters
238+
##
227239
service:
240+
## @param service.type web service type
241+
##
228242
type: ClusterIP
229243
## @param web.podSecurityContext securityContext for the web pod
230244
##
@@ -294,6 +308,14 @@ worker:
294308
# name: foo
295309
# - configMapRef:
296310
# name: bar
311+
## @param worker.nodeSelector Node labels for worker pods assignment
312+
## Ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/
313+
##
314+
nodeSelector: {}
315+
## @param worker.tolerations Tolerations for worker pods assignment
316+
## Ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
317+
##
318+
tolerations: []
297319

298320
workerBeat:
299321
## @param workerBeat.extraEnvVars Extra environment variables (templated) to be added to the pods.
@@ -328,6 +350,14 @@ workerBeat:
328350
# name: foo
329351
# - configMapRef:
330352
# name: bar
353+
## @param workerBeat.nodeSelector Node labels for workerBeat pods assignment
354+
## Ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/
355+
##
356+
nodeSelector: {}
357+
## @param workerBeat.tolerations Tolerations for workerBeat pods assignment
358+
## Ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
359+
##
360+
tolerations: []
331361

332362
persistence:
333363
enabled: true

0 commit comments

Comments
 (0)