templates/_helpers.tpl aktualisiert

This commit is contained in:
2025-11-06 14:55:46 +00:00
parent ebd91dc8c3
commit ae2a878d67

View File

@@ -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 -}}