From b2788502883875aa9948c24803fce6f99e617f8e Mon Sep 17 00:00:00 2001 From: Brandon Marick Date: Wed, 10 Apr 2024 20:05:49 -0700 Subject: [PATCH] Stop generating the checksum labels for Auth Secret when existing secret provided (#392) --- CHANGELOG.md | 1 + templates/deployments.yaml | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 855ade7b..d8a2be78 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ * Fix syntax with ensure-packs-volumes-are-writable job (#403) (by @skiedude) * Add securityContext support to custom st2packs images, extra_hooks jobs; Also fallback to st2actionrunner securityContext for misc init container jobs and pods. (#410) (by @cognifloyd) * Stop generating the DataStore Secret (#385) and checksum labels (#391) when existing secret provided or disabled (by @bmarick) +* Stop generating the checksum labels for Auth Secret (#392) when existing secret provided or disabled (by @bmarick) ## v1.0.0 * Bump to latest CircleCI orb versions (kubernetes@1.3.1 and helm@3.0.0 by @ZoeLeah) diff --git a/templates/deployments.yaml b/templates/deployments.yaml index d66b0de1..3acada39 100644 --- a/templates/deployments.yaml +++ b/templates/deployments.yaml @@ -28,7 +28,9 @@ spec: labels: {{- include "stackstorm-ha.labels" (list $ "st2auth") | nindent 8 }} annotations: checksum/config: {{ include (print $.Template.BasePath "/configmaps_st2-conf.yaml") . | sha256sum }} + {{- if not .Values.st2.existingAuthSecret }} checksum/auth: {{ include (print $.Template.BasePath "/secrets_st2auth.yaml") . | sha256sum }} + {{- end }} {{- if .Values.st2auth.postStartScript }} checksum/post-start-script: {{ .Values.st2auth.postStartScript | sha256sum }} {{- end }} @@ -1584,7 +1586,9 @@ spec: checksum/config: {{ include (print $.Template.BasePath "/configmaps_st2-conf.yaml") . | sha256sum }} checksum/rbac: {{ include (print $.Template.BasePath "/configmaps_rbac.yaml") . | sha256sum }} checksum/packs: {{ include (print $.Template.BasePath "/configmaps_packs.yaml") . | sha256sum }} + {{- if not .Values.st2.existingAuthSecret }} checksum/auth: {{ include (print $.Template.BasePath "/secrets_st2auth.yaml") . | sha256sum }} + {{- end }} checksum/ssh: {{ include (print $.Template.BasePath "/secrets_ssh.yaml") . | sha256sum }} {{- if and (ne "disable" (default "" .Values.st2.datastore_crypto_key)) (not .Values.st2.existingDatastoreSecret) }} checksum/datastore-key: {{ include (print $.Template.BasePath "/secrets_datastore_crypto_key.yaml") . | sha256sum }}