fix when we create serviceAccount value for master and volume statefulsets to be when global.createClusterRole is set to true

This commit is contained in:
jessebot 2023-11-26 14:25:49 +01:00 committed by Chris Lu
parent 0709361ed2
commit d198fd8af7
2 changed files with 2 additions and 2 deletions

View file

@ -55,7 +55,7 @@ spec:
priorityClassName: {{ .Values.master.priorityClassName | quote }} priorityClassName: {{ .Values.master.priorityClassName | quote }}
{{- end }} {{- end }}
enableServiceLinks: false enableServiceLinks: false
{{- if .Values.master.serviceAccountName }} {{- if .Values.global.createClusterRole }}
serviceAccountName: {{ default .Values.global.serviceAccountName .Values.master.serviceAccountName }} # for deleting statefulset pods after migration serviceAccountName: {{ default .Values.global.serviceAccountName .Values.master.serviceAccountName }} # for deleting statefulset pods after migration
{{- end }} {{- end }}
{{- if .Values.master.initContainers }} {{- if .Values.master.initContainers }}

View file

@ -49,7 +49,7 @@ spec:
priorityClassName: {{ .Values.volume.priorityClassName | quote }} priorityClassName: {{ .Values.volume.priorityClassName | quote }}
{{- end }} {{- end }}
enableServiceLinks: false enableServiceLinks: false
{{- if .Values.volume.serviceAccountName }} {{- if .Values.global.createClusterRole }}
serviceAccountName: {{ default .Values.global.serviceAccountName .Values.volume.serviceAccountName }} # for deleting statefulset pods after migration serviceAccountName: {{ default .Values.global.serviceAccountName .Values.volume.serviceAccountName }} # for deleting statefulset pods after migration
{{- end }} {{- end }}
{{- $initContainers_exists := include "volume.initContainers_exists" . -}} {{- $initContainers_exists := include "volume.initContainers_exists" . -}}