From 714bf873b699d11dd331c4209d3991741bbcf99c Mon Sep 17 00:00:00 2001 From: bhearn7 Date: Mon, 23 Aug 2021 13:48:48 -0400 Subject: [PATCH] testing --- CHANGELOG.md | 4 +++- chart/templates/engine_secret.yaml | 4 ++-- chart/templates/enterprise_feeds_secret.yaml | 4 ++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9c48307..8b64575 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,9 +7,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), ## [1.13.0-bb.7] ### Fixed - to resolve an issue where Anchore would redeploy after every update, `./chart/templates/engine_secret.yaml` and `./chart/templates/enterprise_feeds_secret.yaml` were modified to set `ANCHORE_SAML_SECRET` to a randomly generated value if not set and the previous secret does not exist +### Changed +- set `.Values.anchoreGlobal.saml.secret` to an empty string rather than `Null` (the default) so it would evaluate to **false** when not configured ## [1.13.0-bb.6] -## Changed +### Changed - updated bb-test-lib dependency to gluon `0.2.3` to resolve OPA Gatekeeper violations - updated Redis dependency to `14.1.0-bb.3` to resolve OPA Gatekeeper violations - set resource requests and limits for all containers to resolve OPA Gatekeeper violations diff --git a/chart/templates/engine_secret.yaml b/chart/templates/engine_secret.yaml index 9138cf9..6442831 100644 --- a/chart/templates/engine_secret.yaml +++ b/chart/templates/engine_secret.yaml @@ -16,9 +16,9 @@ stringData: ANCHORE_DB_PASSWORD: {{ index .Values "postgresql" "postgresPassword" | quote }} {{- $anchorefullname := include "anchore-engine.fullname" . -}} {{- $old_secret := lookup "v1" "Secret" .Release.Namespace $anchorefullname }} - {{- if or (not $old_secret) (not $old_secret.data) }} + {{- if or (not $old_secret) (not $old_secret.stringData) }} ANCHORE_SAML_SECRET: {{ .Values.anchoreGlobal.saml.secret | default (randAlphaNum 12) | quote }} {{ else }} - ANCHORE_SAML_SECRET: {{ index $old_secret.data "ANCHORE_SAML_SECRET" }} + ANCHORE_SAML_SECRET: {{ index $old_secret.stringData "ANCHORE_SAML_SECRET" }} {{- end }} {{- end }} \ No newline at end of file diff --git a/chart/templates/enterprise_feeds_secret.yaml b/chart/templates/enterprise_feeds_secret.yaml index 924c11b..2c66d0c 100644 --- a/chart/templates/enterprise_feeds_secret.yaml +++ b/chart/templates/enterprise_feeds_secret.yaml @@ -17,10 +17,10 @@ stringData: ANCHORE_FEEDS_DB_PASSWORD: {{ index .Values "anchore-feeds-db" "postgresPassword" | quote }} {{- $anchorefullname := include "anchore-engine.fullname" . -}} {{- $old_secret := lookup "v1" "Secret" .Release.Namespace $anchorefullname }} - {{- if or (not $old_secret) (not $old_secret.data) }} + {{- if or (not $old_secret) (not $old_secret.stringData) }} ANCHORE_SAML_SECRET: {{ .Values.anchoreGlobal.saml.secret | default (randAlphaNum 12) | quote }} {{ else }} - ANCHORE_SAML_SECRET: {{ index $old_secret.data "ANCHORE_SAML_SECRET" }} + ANCHORE_SAML_SECRET: {{ index $old_secret.stringData "ANCHORE_SAML_SECRET" }} {{- end }} {{- with .Values.anchoreEnterpriseFeeds.msrcApiKey }} ANCHORE_MSRC_KEY: {{ . | quote }} -- GitLab