From b444357a0f3f6ccfac6f9f539145937855a92826 Mon Sep 17 00:00:00 2001 From: CrimsonRot Date: Fri, 18 Oct 2024 08:50:21 +0200 Subject: [PATCH] added imagepullsecrets Signed-off-by: CrimsonRot --- .../templates/post-install-hook.yaml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/charts/kubewarden-controller/templates/post-install-hook.yaml b/charts/kubewarden-controller/templates/post-install-hook.yaml index 148ec58b..53954c1b 100644 --- a/charts/kubewarden-controller/templates/post-install-hook.yaml +++ b/charts/kubewarden-controller/templates/post-install-hook.yaml @@ -34,6 +34,10 @@ spec: {{- if .Values.preDeleteHook.podSecurityContext }} securityContext: {{ toYaml .Values.preDeleteHook.podSecurityContext | indent 8 }} + {{- end }} + {{- if .Values.imagePullSecrets }} + imagePullSecrets: + {{- include "imagePullSecrets" .Values.imagePullSecrets | nindent 8 }} {{- end }} containers: - name: post-install-job @@ -85,6 +89,10 @@ spec: {{- if .Values.preDeleteHook.podSecurityContext }} securityContext: {{ toYaml .Values.preDeleteHook.podSecurityContext | indent 8 }} + {{- end }} + {{- if .Values.imagePullSecrets }} + imagePullSecrets: + {{- include "imagePullSecrets" .Values.imagePullSecrets | nindent 8 }} {{- end }} containers: - name: delete-pre-1-11-policyreports-job @@ -94,7 +102,7 @@ spec: securityContext: {{ toYaml .Values.preDeleteHook.containerSecurityContext | indent 12 }} {{- end }} - + --- # Delete pre 1.17 webhook certificates secret. apiVersion: batch/v1 @@ -127,6 +135,10 @@ spec: {{- if .Values.preDeleteHook.podSecurityContext }} securityContext: {{ toYaml .Values.preDeleteHook.podSecurityContext | indent 8 }} + {{- end }} + {{- if .Values.imagePullSecrets }} + imagePullSecrets: + {{- include "imagePullSecrets" .Values.imagePullSecrets | nindent 8 }} {{- end }} containers: - name: del-pre-1-17-webhook-srv-cert