This commit is contained in:
21
templates/backup-secret.yaml
Normal file
21
templates/backup-secret.yaml
Normal file
@@ -0,0 +1,21 @@
|
||||
{{- if and .Values.backup.enabled (not .Values.backup.mysql.existingSecret) }}
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: {{ include "phpmyadmin-nginx.fullname" . }}-backup
|
||||
labels:
|
||||
{{- include "phpmyadmin-nginx.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: backup
|
||||
type: Opaque
|
||||
data:
|
||||
{{- if .Values.backup.mysql.user }}
|
||||
mysql-user: {{ .Values.backup.mysql.user | b64enc | quote }}
|
||||
{{- else }}
|
||||
mysql-user: {{ "backup" | b64enc | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.backup.mysql.password }}
|
||||
mysql-password: {{ .Values.backup.mysql.password | b64enc | quote }}
|
||||
{{- else }}
|
||||
mysql-password: {{ randAlphaNum 32 | b64enc | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
Reference in New Issue
Block a user