From 342e2796494f04017b55e8882874f58545fb7454 Mon Sep 17 00:00:00 2001 From: Chris Werner Rau Date: Wed, 26 Feb 2025 10:06:34 +0100 Subject: [PATCH] feat(base-cluster): use new pullPolicy template --- .../templates/backup/migrations/velero-4-to-5.yaml | 2 +- .../flux/_create-authentication-key-secret-job.yaml | 6 +++--- .../templates/global/prevent-uninstallation.yaml | 2 +- .../templates/monitoring/deadMansSwitch/cronjob.yaml | 2 +- .../templates/monitoring/deadMansSwitch/registration.yaml | 2 +- .../templates/monitoring/deadMansSwitch/unregister.yaml | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/charts/base-cluster/templates/backup/migrations/velero-4-to-5.yaml b/charts/base-cluster/templates/backup/migrations/velero-4-to-5.yaml index 6aa566236c..ab33c0f2ed 100644 --- a/charts/base-cluster/templates/backup/migrations/velero-4-to-5.yaml +++ b/charts/base-cluster/templates/backup/migrations/velero-4-to-5.yaml @@ -23,7 +23,7 @@ spec: containers: - name: remove-backup-storage-locations image: {{ include "common.images.image" (dict "imageRoot" .Values.global.kubectl.image "global" .Values.global) }} - imagePullPolicy: {{ empty .Values.global.kubectl.image.digest | ternary "Always" "IfNotPresent" }} + imagePullPolicy: {{ include "common.images.pullPolicy" .Values.global.kubectl.image }} securityContext: readOnlyRootFilesystem: true privileged: false diff --git a/charts/base-cluster/templates/flux/_create-authentication-key-secret-job.yaml b/charts/base-cluster/templates/flux/_create-authentication-key-secret-job.yaml index 8936ff2d39..81b70abc6d 100644 --- a/charts/base-cluster/templates/flux/_create-authentication-key-secret-job.yaml +++ b/charts/base-cluster/templates/flux/_create-authentication-key-secret-job.yaml @@ -27,7 +27,7 @@ spec: containers: - name: generate-ssh-key image: {{ template "base-cluster.flux.image" .context }} - imagePullPolicy: {{ empty .Values.global.flux.image.digest | ternary "Always" "IfNotPresent" }} + imagePullPolicy: {{ include "common.images.pullPolicy" .Values.global.flux.image }} securityContext: readOnlyRootFilesystem: true privileged: false @@ -49,7 +49,7 @@ spec: initContainers: - name: generate-gpg-key image: {{ template "base-cluster.gpg.image" .context }} - imagePullPolicy: {{ empty .Values.global.gpg.image.digest | ternary "Always" "IfNotPresent" }} + imagePullPolicy: {{ include "common.images.pullPolicy" .Values.global.gpg.image }} env: - name: IDENTITY value: {{ .identity }} @@ -89,7 +89,7 @@ spec: containers: - name: create-k8s-secret image: {{ include "base-cluster.kubectl.image" .context }} - imagePullPolicy: {{ empty .Values.global.kubectl.image.digest | ternary "Always" "IfNotPresent" }} + imagePullPolicy: {{ include "common.images.pullPolicy" .Values.global.kubectl.image }} securityContext: readOnlyRootFilesystem: true privileged: false diff --git a/charts/base-cluster/templates/global/prevent-uninstallation.yaml b/charts/base-cluster/templates/global/prevent-uninstallation.yaml index 2855d47dc5..5d98705e8b 100644 --- a/charts/base-cluster/templates/global/prevent-uninstallation.yaml +++ b/charts/base-cluster/templates/global/prevent-uninstallation.yaml @@ -22,7 +22,7 @@ spec: containers: - name: fail image: {{ template "base-cluster.kubectl.image" . }} - imagePullPolicy: {{ empty .Values.global.kubectl.image.digest | ternary "Always" "IfNotPresent" }} + imagePullPolicy: {{ include "common.images.pullPolicy" .Values.global.kubectl.image }} securityContext: readOnlyRootFilesystem: true privileged: false diff --git a/charts/base-cluster/templates/monitoring/deadMansSwitch/cronjob.yaml b/charts/base-cluster/templates/monitoring/deadMansSwitch/cronjob.yaml index 3a930045db..cc66cac84a 100644 --- a/charts/base-cluster/templates/monitoring/deadMansSwitch/cronjob.yaml +++ b/charts/base-cluster/templates/monitoring/deadMansSwitch/cronjob.yaml @@ -33,7 +33,7 @@ spec: containers: - name: watchdog image: {{ template "base-cluster.curl.image" . }} - imagePullPolicy: {{ empty .Values.global.curl.image.digest | ternary "Always" "IfNotPresent" }} + imagePullPolicy: {{ include "common.images.pullPolicy" .Values.global.curl.image }} securityContext: allowPrivilegeEscalation: false capabilities: diff --git a/charts/base-cluster/templates/monitoring/deadMansSwitch/registration.yaml b/charts/base-cluster/templates/monitoring/deadMansSwitch/registration.yaml index 4c1d97b385..af7057ba5a 100644 --- a/charts/base-cluster/templates/monitoring/deadMansSwitch/registration.yaml +++ b/charts/base-cluster/templates/monitoring/deadMansSwitch/registration.yaml @@ -28,7 +28,7 @@ spec: containers: - name: register image: {{ include "base-cluster.curl.image" . }} - imagePullPolicy: {{ empty .Values.global.curl.image.digest | ternary "Always" "IfNotPresent" }} + imagePullPolicy: {{ include "common.images.pullPolicy" .Values.global.curl.image }} securityContext: allowPrivilegeEscalation: false capabilities: diff --git a/charts/base-cluster/templates/monitoring/deadMansSwitch/unregister.yaml b/charts/base-cluster/templates/monitoring/deadMansSwitch/unregister.yaml index ed425fb1e3..9011228aa9 100644 --- a/charts/base-cluster/templates/monitoring/deadMansSwitch/unregister.yaml +++ b/charts/base-cluster/templates/monitoring/deadMansSwitch/unregister.yaml @@ -24,7 +24,7 @@ spec: containers: - name: unregister image: {{ include "base-cluster.curl.image" . }} - imagePullPolicy: {{ empty .Values.global.curl.image.digest | ternary "Always" "IfNotPresent" }} + imagePullPolicy: {{ include "common.images.pullPolicy" .Values.global.curl.image }} securityContext: allowPrivilegeEscalation: false capabilities: