Support templating accessKey existingSecret and bucket name (#14643)

This commit is contained in:
Yi Siqi
2022-04-14 02:58:29 +08:00
committed by GitHub
parent 5c53620a72
commit 7ce1f6e736
3 changed files with 8 additions and 5 deletions
+3 -2
View File
@@ -76,12 +76,13 @@ scheme=http
connectToMinio $scheme
{{ if .Values.users }}
{{ $global := . }}
# Create the users
{{- range .Values.users }}
{{- if .existingSecret }}
createUser {{ .accessKey }} $(cat /config/secrets/{{ .accessKey }}) {{ .policy }}
createUser {{ tpl .accessKey $global }} $(cat /config/secrets/{{ tpl .accessKey $global }}) {{ .policy }}
{{ else }}
createUser {{ .accessKey }} {{ .secretKey }} {{ .policy }}
createUser {{ tpl .accessKey $global }} {{ .secretKey }} {{ .policy }}
{{- end }}
{{- end }}
{{- end }}