Skip to content

Commit

Permalink
fix access data node affinity
Browse files Browse the repository at this point in the history
  • Loading branch information
raresfirebolt committed Jun 26, 2021
1 parent 747c09d commit 37ee54e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,9 @@ spec:
{{- if .Values.schedulerName }}
schedulerName: {{ .Values.schedulerName }}
{{- end }}
{{- if .Values.affinity }}
{{- if .Values.accessNode.affinity }}
affinity:
{{ .Values.affinity | toYaml | indent 8 }}
{{ .Values.accessNode.affinity | toYaml | indent 8 }}
{{- else if .Values.affinityTemplate }}
affinity:
{{ tpl .Values.affinityTemplate . | indent 8 }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,9 +117,9 @@ spec:
{{- if .Values.schedulerName }}
schedulerName: {{ .Values.schedulerName }}
{{- end }}
{{- if .Values.affinity }}
{{- if .Values.dataNode.affinity }}
affinity:
{{ .Values.affinity | toYaml | indent 8 }}
{{ .Values.dataNode.affinity | toYaml | indent 8 }}
{{- else if .Values.affinityTemplate }}
affinity:
{{ tpl .Values.affinityTemplate . | indent 8 }}
Expand Down
13 changes: 6 additions & 7 deletions charts/timescaledb-multinode/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,9 @@ accessNode:
accessModes:
- ReadWriteOnce

nodeSelector: {}
tolerations: []
affinity: {}
nodeSelector: {}
tolerations: []
affinity: {}

dataNode:
replicas: 3
Expand Down Expand Up @@ -118,10 +118,9 @@ dataNode:
accessModes:
- ReadWriteOnce

nodeSelector: {}
tolerations: []
affinity: {}

nodeSelector: {}
tolerations: []
affinity: {}

# https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity
affinityTemplate: |
Expand Down

0 comments on commit 37ee54e

Please sign in to comment.