From f294a8e5a323cb548325fa61b18da234646d72ea Mon Sep 17 00:00:00 2001 From: Johannes Kastl Date: Sat, 7 Feb 2026 17:18:34 +0100 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8(helm)=20allow=20all=20keys=20in=20con?= =?UTF-8?q?figMap=20as=20env=20var=20in=20backend=20jobs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add `envFrom` support to backend jobs and cronjobs (`backend_job.yml`, `backend_job_createsuperuser.yaml`, `backend_job_migrate.yaml`, `backend_cronjob_list.yaml`), mirroring the `envFrom` support already added to the deployments. This allows injecting all keys from a ConfigMap or Secret as environment variables via `backend.envFrom` in the Helm values. Signed-off-by: Johannes Kastl --- CHANGELOG.md | 4 ++++ src/helm/impress/templates/backend_cronjob_list.yaml | 4 ++++ src/helm/impress/templates/backend_job.yml | 4 ++++ src/helm/impress/templates/backend_job_createsuperuser.yaml | 4 ++++ src/helm/impress/templates/backend_job_migrate.yaml | 4 ++++ 5 files changed, 20 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 65c0407ed..ed109df21 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,10 @@ and this project adheres to ## [Unreleased] +### Added + +- ✨(helm) allow all keys in configMap as env var #1872 + ### Changed - 📝(docs) improve README and add documentation hub #1870 diff --git a/src/helm/impress/templates/backend_cronjob_list.yaml b/src/helm/impress/templates/backend_cronjob_list.yaml index 06b1af54d..df2d5ab1e 100644 --- a/src/helm/impress/templates/backend_cronjob_list.yaml +++ b/src/helm/impress/templates/backend_cronjob_list.yaml @@ -42,6 +42,10 @@ items: env: {{- $envVars | indent 22 }} {{- end }} + {{- if .Values.backend.envFrom }} + envFrom: + {{- toYaml .Values.backend.envFrom | nindent 22 }} + {{- end }} {{- with $.Values.backend.securityContext }} securityContext: {{- toYaml . | nindent 22 }} diff --git a/src/helm/impress/templates/backend_job.yml b/src/helm/impress/templates/backend_job.yml index 117722f04..397f4cfbe 100644 --- a/src/helm/impress/templates/backend_job.yml +++ b/src/helm/impress/templates/backend_job.yml @@ -48,6 +48,10 @@ spec: env: {{- $envVars | indent 12 }} {{- end }} + {{- if .Values.backend.envFrom }} + envFrom: + {{- toYaml .Values.backend.envFrom | nindent 12 }} + {{- end }} {{- with .Values.backend.securityContext }} securityContext: {{- toYaml . | nindent 12 }} diff --git a/src/helm/impress/templates/backend_job_createsuperuser.yaml b/src/helm/impress/templates/backend_job_createsuperuser.yaml index 40650b823..76c230ce0 100644 --- a/src/helm/impress/templates/backend_job_createsuperuser.yaml +++ b/src/helm/impress/templates/backend_job_createsuperuser.yaml @@ -52,6 +52,10 @@ spec: env: {{- $envVars | indent 12 }} {{- end }} + {{- if .Values.backend.envFrom }} + envFrom: + {{- toYaml .Values.backend.envFrom | nindent 12 }} + {{- end }} {{- with .Values.backend.securityContext }} securityContext: {{- toYaml . | nindent 12 }} diff --git a/src/helm/impress/templates/backend_job_migrate.yaml b/src/helm/impress/templates/backend_job_migrate.yaml index 981e3d9f1..28ce98978 100644 --- a/src/helm/impress/templates/backend_job_migrate.yaml +++ b/src/helm/impress/templates/backend_job_migrate.yaml @@ -52,6 +52,10 @@ spec: env: {{- $envVars | indent 12 }} {{- end }} + {{- if .Values.backend.envFrom }} + envFrom: + {{- toYaml .Values.backend.envFrom | nindent 12 }} + {{- end }} {{- with .Values.backend.securityContext }} securityContext: {{- toYaml . | nindent 12 }}