From ae2a878d678b791cd54c6589db9a9a8f7b941c5f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn=20Ahlers?= Date: Thu, 6 Nov 2025 14:55:46 +0000 Subject: [PATCH] templates/_helpers.tpl aktualisiert --- templates/_helpers.tpl | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/templates/_helpers.tpl b/templates/_helpers.tpl index fffa74c..1bcdd72 100644 --- a/templates/_helpers.tpl +++ b/templates/_helpers.tpl @@ -65,3 +65,19 @@ Create the name of the service account to use {{- end }} {{- end }} +{{/* +Return the MariaDB Secret Name +*/}} +{{- define "librebooking.databaseSecretName" -}} +{{- if .Values.mariadb.enabled }} + {{- if .Values.mariadb.auth.existingSecret -}} + {{- printf "%s" .Values.mariadb.auth.existingSecret -}} + {{- else -}} + {{- printf "%s" (include "librebooking.mariadb.fullname" .) -}} + {{- end -}} +{{- else if .Values.externalDatabase.existingSecret -}} + {{- printf "%s" .Values.externalDatabase.existingSecret -}} +{{- else -}} + {{- printf "%s-db-secrets" (include "librebooking.fullname" .) -}} +{{- end -}} +{{- end -}} \ No newline at end of file