Skip to content

Commit

Permalink
affinity stanzas in provider pods (#725)
Browse files Browse the repository at this point in the history
* affinity stanzas in provider pods 
* fix provider affinity macro

Co-authored-by: hunhoffe
  • Loading branch information
dgrove-oss authored Mar 8, 2022
1 parent d5addf9 commit 43c15b3
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
1 change: 0 additions & 1 deletion helm/openwhisk/templates/_affinity.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ nodeAffinity:
operator: NotIn
values:
- {{ .Values.affinity.invokerNodeLabel }}
preferredDuringSchedulingIgnoredDuringExecution:
- weight: 80
preference:
matchExpressions:
Expand Down
6 changes: 6 additions & 0 deletions helm/openwhisk/templates/provider-alarm-pod.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,12 @@ spec:
{{- else }}
emptyDir: {}
{{- end }}

{{- if .Values.affinity.enabled }}
affinity:
{{ include "openwhisk.affinity.provider" . | indent 8 }}
{{- end }}

initContainers:
# Wait for a controller to be up (which implies couchdb is up as well).
{{ include "openwhisk.readiness.waitForController" . | indent 6 }}
Expand Down
4 changes: 4 additions & 0 deletions helm/openwhisk/templates/provider-kafka-pod.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@ spec:
{{ include "openwhisk.label_boilerplate" . | indent 8 }}
spec:
restartPolicy: {{ .Values.providers.kafka.restartPolicy }}
{{- if .Values.affinity.enabled }}
affinity:
{{ include "openwhisk.affinity.provider" . | indent 8 }}
{{- end }}
initContainers:
# Wait for a controller to be up (which implies couchdb and kafka are up as well).
{{ include "openwhisk.readiness.waitForController" . | indent 6 }}
Expand Down

0 comments on commit 43c15b3

Please sign in to comment.