From 6d3cd5777b3b3a516b03cad63be8055f1eb38be1 Mon Sep 17 00:00:00 2001 From: Ben Jackson Date: Tue, 29 Nov 2022 16:36:28 +1100 Subject: [PATCH] fix: replace special chars with underscore for postgres-single backups --- legacy/helmcharts/postgres-single/templates/deployment.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/legacy/helmcharts/postgres-single/templates/deployment.yaml b/legacy/helmcharts/postgres-single/templates/deployment.yaml index d57c9953..7e57e40c 100644 --- a/legacy/helmcharts/postgres-single/templates/deployment.yaml +++ b/legacy/helmcharts/postgres-single/templates/deployment.yaml @@ -25,7 +25,7 @@ spec: {{- end }} annotations: {{- include "postgres-single.annotations" . | nindent 8 }} - k8up.syn.tools/backupcommand: /bin/sh -c "PGPASSWORD=${{ upper .Release.Name }}_PASSWORD pg_dump --host=localhost --port=${{ upper .Release.Name }}_SERVICE_PORT --dbname=${{ upper .Release.Name }}_DB --username=${{ upper .Release.Name }}_USER --format=t -w" + k8up.syn.tools/backupcommand: /bin/sh -c "PGPASSWORD=${{ regexReplaceAll "\\W+" .Release.Name "_" | upper }}_PASSWORD pg_dump --host=localhost --port=${{ regexReplaceAll "\\W+" .Release.Name "_" | upper }}_SERVICE_PORT --dbname=${{ regexReplaceAll "\\W+" .Release.Name "_" | upper }}_DB --username=${{ regexReplaceAll "\\W+" .Release.Name "_" | upper }}_USER --format=t -w" k8up.syn.tools/file-extension: .{{ include "postgres-single.fullname" . }}.tar lagoon.sh/configMapSha: {{ .Values.configMapSha | quote }} spec: