From 86646ba72950ce27a37f279af86181e27ebb1602 Mon Sep 17 00:00:00 2001 From: Juan Ariza Toledano Date: Fri, 4 Feb 2022 08:34:01 +0100 Subject: [PATCH] [bitnami/postgresql] Fix PostgreSLQ password in metrics container (#8901) --- bitnami/postgresql/Chart.yaml | 2 +- bitnami/postgresql/templates/primary/statefulset.yaml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bitnami/postgresql/Chart.yaml b/bitnami/postgresql/Chart.yaml index c7e7df0a1e..ad4a973d3f 100644 --- a/bitnami/postgresql/Chart.yaml +++ b/bitnami/postgresql/Chart.yaml @@ -26,4 +26,4 @@ name: postgresql sources: - https://github.com/bitnami/bitnami-docker-postgresql - https://www.postgresql.org/ -version: 11.0.1 +version: 11.0.2 diff --git a/bitnami/postgresql/templates/primary/statefulset.yaml b/bitnami/postgresql/templates/primary/statefulset.yaml index 3ec53d230c..603bd462c1 100644 --- a/bitnami/postgresql/templates/primary/statefulset.yaml +++ b/bitnami/postgresql/templates/primary/statefulset.yaml @@ -473,13 +473,13 @@ spec: {{- end }} {{- if .Values.auth.usePasswordFiles }} - name: DATA_SOURCE_PASS_FILE - value: "/opt/bitnami/postgresql/secrets/password" + value: {{ printf "/opt/bitnami/postgresql/secrets/%s" (ternary "password" "postgres-password" (and (not (empty $customUser)) (ne $customUser "postgres"))) }} {{- else }} - name: DATA_SOURCE_PASS valueFrom: secretKeyRef: name: {{ include "postgresql.secretName" . }} - key: password + key: {{ ternary "password" "postgres-password" (and (not (empty $customUser)) (ne $customUser "postgres")) }} {{- end }} - name: DATA_SOURCE_USER value: {{ default "postgres" $customUser | quote }}