From 9e442ef1b90463f0e5b353d2808f76f56c368093 Mon Sep 17 00:00:00 2001 From: Stefan Krenz Date: Tue, 24 Sep 2024 10:49:58 +0200 Subject: [PATCH] fix: Merge env vars --- charts/matomo/templates/cronjob-archive.yaml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/charts/matomo/templates/cronjob-archive.yaml b/charts/matomo/templates/cronjob-archive.yaml index 3fde8b5..9fe215d 100644 --- a/charts/matomo/templates/cronjob-archive.yaml +++ b/charts/matomo/templates/cronjob-archive.yaml @@ -51,11 +51,8 @@ spec: value: {{ .Values.database.dbname | quote }} - name: MATOMO_GENERAL_SALT value: {{ required "`.Values.salt` is not set." .Values.salt | quote }} - {{- range $key, $value := .Values.extraEnvs }} - - name: {{ $key }} - value: {{ $value | quote }} - {{- end }} - {{- range $key, $value := .Values.cronjobs.archive.extraEnvs }} + {{- $extraEnvs := (deepCopy .Values.extraEnvs | mergeOverwrite .Values.cronjobs.archive.extraEnvs) }} + {{- range $key, $value := $extraEnvs }} - name: {{ $key }} value: {{ $value | quote }} {{- end }}