Add standalone R3 RIC platform helm charts and deployment scripts.
[ric-plt/ric-dep.git] / helm / infrastructure / subcharts / kong / charts / postgresql / templates / secrets.yaml
1 {{- if not .Values.existingSecret }}
2 apiVersion: v1
3 kind: Secret
4 metadata:
5   name: {{ template "postgresql.fullname" . }}
6   labels:
7     app: {{ template "postgresql.name" . }}
8     chart: {{ template "postgresql.chart" . }}
9     release: {{ .Release.Name | quote }}
10     heritage: {{ .Release.Service | quote }}
11 type: Opaque
12 data:
13   {{- if .Values.postgresqlPassword }}
14   postgresql-password: {{ .Values.postgresqlPassword | b64enc | quote }}
15   {{- else }}
16   postgresql-password: {{ randAlphaNum 10 | b64enc | quote }}
17   {{- end }}
18   {{- if .Values.replication.enabled }}
19   {{- if .Values.replication.password }}
20   postgresql-replication-password: {{ .Values.replication.password | b64enc | quote }}
21   {{- else }}
22   postgresql-replication-password: {{ randAlphaNum 10 | b64enc | quote }}
23   {{- end }}
24   {{- end }}
25 {{- end -}}