From d4c85ecfc494ee2abe912ec782c8d356ff363f9c Mon Sep 17 00:00:00 2001 From: Alex Miller Date: Thu, 23 Feb 2023 01:27:13 -0500 Subject: [PATCH] Use emptyDir for pgbackrest repo1-path Creates the directory defined by repo1-path, to be used as the pgBackRest repository, as described in their user guide: https://pgbackrest.org/user-guide.html#quickstart/create-repository Resolves this error during pgbackrest_bootstrap.sh: ERROR: [103]: unable to find a valid repository: repo1: [FileMissingError] unable to load info file ... Signed-off-by: Alex Miller --- charts/timescaledb-single/Chart.yaml | 2 +- .../templates/statefulset-timescaledb.yaml | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/charts/timescaledb-single/Chart.yaml b/charts/timescaledb-single/Chart.yaml index 697ffb69..84e86776 100644 --- a/charts/timescaledb-single/Chart.yaml +++ b/charts/timescaledb-single/Chart.yaml @@ -4,7 +4,7 @@ apiVersion: v1 name: timescaledb-single description: 'TimescaleDB HA Deployment.' -version: 0.33.1 +version: 0.33.2 icon: https://cdn.iconscout.com/icon/free/png-256/timescaledb-1958407-1651618.png # appVersion specifies the version of the software, which can vary wildly, diff --git a/charts/timescaledb-single/templates/statefulset-timescaledb.yaml b/charts/timescaledb-single/templates/statefulset-timescaledb.yaml index 7e63437d..f48c5ae1 100644 --- a/charts/timescaledb-single/templates/statefulset-timescaledb.yaml +++ b/charts/timescaledb-single/templates/statefulset-timescaledb.yaml @@ -401,6 +401,8 @@ spec: - mountPath: /etc/pgbackrest_secrets name: pgbackrest-secrets readOnly: true + - mountPath: {{ index .Values.backup.pgBackRest "repo1-path" | default (printf "/%s/%s/" .Release.Namespace (include "clusterName" .)) | quote }} + name: pgbackrest-repo env: - name: PGHOST value: /var/run/postgresql @@ -528,6 +530,10 @@ spec: secret: secretName: {{ .Values.bootstrapFromBackup.secretName }} optional: True + {{- if or .Values.backup.enabled .Values.backup.enable }} + - name: pgbackrest-repo + emptyDir: {} + {{- end }} {{- if not .Values.persistentVolumes.data.enabled }} - name: storage-volume emptyDir: {}