From 41ca15fde0454aafca68e9bd581d2f5af509aa7e Mon Sep 17 00:00:00 2001 From: Itay Grudev Date: Fri, 13 Oct 2023 01:35:02 +0300 Subject: [PATCH] Bug Fix: Azure connectionString exclusion depending on configuration method Signed-off-by: Itay Grudev --- charts/cluster/templates/_barman_object_store.tpl | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/charts/cluster/templates/_barman_object_store.tpl b/charts/cluster/templates/_barman_object_store.tpl index b7a6c6c282..96278f11a5 100644 --- a/charts/cluster/templates/_barman_object_store.tpl +++ b/charts/cluster/templates/_barman_object_store.tpl @@ -27,18 +27,24 @@ destinationPath: "https://{{ required "You need to specify Azure storageAccount if destinationPath is not specified." .scope.azure.storageAccount }}.{{ .scope.azure.serviceName }}.core.windows.net/{{ .scope.azure.containerName }}{{ .scope.azure.path }}" {{- end }} azureCredentials: + {{- if .scope.azure.connectionString }} connectionString: name: {{ .chartFullname }}-backup-azure{{ .secretSuffix }}-creds key: AZURE_CONNECTION_STRING + {{- else }} storageAccount: name: {{ .chartFullname }}-backup-azure{{ .secretSuffix }}-creds key: AZURE_STORAGE_ACCOUNT + {{- if .scope.azure.storageKey }} storageKey: name: {{ .chartFullname }}-backup-azure{{ .secretSuffix }}-creds key: AZURE_STORAGE_KEY + {{- else }} storageSasToken: name: {{ .chartFullname }}-backup-azure{{ .secretSuffix }}-creds key: AZURE_STORAGE_SAS_TOKEN + {{- end }} + {{- end }} {{- else if eq .scope.provider "google" }} {{- if empty .scope.destinationPath }} destinationPath: "gs://{{ required "You need to specify Google storage bucket if destinationPath is not specified." .scope.google.bucket }}{{ .scope.google.path }}"