{{- if not .Values.useExistingSecret }} --- apiVersion: v1 kind: Secret metadata: name: '{{ .Values.defaultUserCredentialsSecret }}' namespace: {{ .Release.Namespace }} labels: {{ include "s3gw.labels" . | indent 4 }} type: Opaque stringData: RGW_DEFAULT_USER_ACCESS_KEY: {{ include "s3gw.defaultAccessKey" . | quote }} RGW_DEFAULT_USER_SECRET_KEY: {{ include "s3gw.defaultSecretKey" . | quote }} {{- end }} {{- if .Values.imageCredentials }} --- apiVersion: v1 kind: Secret metadata: name: '{{ .Chart.Name }}-image-pull-secret' namespace: {{ .Release.Namespace }} labels: {{ include "s3gw.labels" . | indent 4 }} type: kubernetes.io/dockerconfigjson data: .dockerconfigjson: {{ template "s3gw.imagePullSecret" . }} {{- end }}