prefer global.serviceAccountName when available for all statefulsets

This commit is contained in:
jessebot 2023-11-26 14:00:15 +01:00 committed by Chris Lu
parent aff03c1d00
commit c332832f0b
3 changed files with 3 additions and 3 deletions

View file

@ -52,7 +52,7 @@ spec:
{{- end }} {{- end }}
{{- include "seaweedfs.imagePullSecrets" . | nindent 6 }} {{- include "seaweedfs.imagePullSecrets" . | nindent 6 }}
{{- if .Values.global.createClusterRole }} {{- if .Values.global.createClusterRole }}
serviceAccountName: seaweedfs-rw-sa #hack for delete pod master after migration serviceAccountName: {{ default .Values.global.serviceAccountName .Values.filer.serviceAccountName }} # for deleting statefulset pods after migration
{{- end }} {{- end }}
terminationGracePeriodSeconds: 60 terminationGracePeriodSeconds: 60
{{- if .Values.filer.priorityClassName }} {{- if .Values.filer.priorityClassName }}

View file

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

View file

@ -50,7 +50,7 @@ spec:
{{- end }} {{- end }}
enableServiceLinks: false enableServiceLinks: false
{{- if .Values.volume.serviceAccountName }} {{- if .Values.volume.serviceAccountName }}
serviceAccountName: {{ .Values.volume.serviceAccountName | quote }} 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" . -}}
{{- if $initContainers_exists }} {{- if $initContainers_exists }}