forked from nextcloud/helm
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsecrets.yaml
More file actions
29 lines (29 loc) · 1.1 KB
/
secrets.yaml
File metadata and controls
29 lines (29 loc) · 1.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
{{- if not .Values.nextcloud.existingSecret.enabled }}
apiVersion: v1
kind: Secret
metadata:
name: {{ template "nextcloud.fullname" . }}
labels:
app.kubernetes.io/name: {{ include "nextcloud.name" . }}
helm.sh/chart: {{ include "nextcloud.chart" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
type: Opaque
data:
nextcloud-username: {{ .Values.nextcloud.username | b64enc | quote }}
{{- with .Values.nextcloud.password }}
nextcloud-password: {{ . | b64enc | quote }}
{{- else }}
nextcloud-password: {{ randAlphaNum 10 | b64enc | quote }}
{{- end }}
{{- with .Values.metrics.token }}
nextcloud-token: {{ . | b64enc | quote }}
{{- else }}
nextcloud-token: {{ randAlphaNum 10 | b64enc | quote }}
{{- end }}
{{- if .Values.nextcloud.mail.enabled }}
smtp-username: {{ .Values.nextcloud.mail.smtp.name | default "" | b64enc | quote }}
smtp-password: {{ .Values.nextcloud.mail.smtp.password | default "" | b64enc | quote }}
smtp-host: {{ .Values.nextcloud.mail.smtp.host | default "" | b64enc | quote }}
{{- end }}
{{- end }}