From ef3ced1259e01220a0a40e0e2736cfcae085d072 Mon Sep 17 00:00:00 2001 From: Gabriel Martinez <19713226+GMartinez-Sisti@users.noreply.github.com> Date: Tue, 7 May 2024 14:07:10 +0100 Subject: [PATCH] fix(atlantis): permissions for .gitconfig file (#384) --- charts/atlantis/Chart.yaml | 2 +- charts/atlantis/templates/statefulset.yaml | 2 ++ charts/atlantis/tests/statefulset_test.yaml | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/charts/atlantis/Chart.yaml b/charts/atlantis/Chart.yaml index e4a1de5a..e9738024 100644 --- a/charts/atlantis/Chart.yaml +++ b/charts/atlantis/Chart.yaml @@ -3,7 +3,7 @@ apiVersion: v1 appVersion: v0.27.3 description: A Helm chart for Atlantis https://www.runatlantis.io name: atlantis -version: 5.0.1 +version: 5.0.2 keywords: - terraform home: https://www.runatlantis.io diff --git a/charts/atlantis/templates/statefulset.yaml b/charts/atlantis/templates/statefulset.yaml index e5b79828..aa11e5ba 100644 --- a/charts/atlantis/templates/statefulset.yaml +++ b/charts/atlantis/templates/statefulset.yaml @@ -86,10 +86,12 @@ spec: {{- if .Values.gitconfig }} - name: gitconfig-volume secret: + defaultMode: 0660 secretName: {{ template "atlantis.fullname" . }}-gitconfig {{- else if .Values.gitconfigSecretName }} - name: gitconfig-volume secret: + defaultMode: 0660 secretName: {{ .Values.gitconfigSecretName }} {{- end }} {{- if .Values.netrc }} diff --git a/charts/atlantis/tests/statefulset_test.yaml b/charts/atlantis/tests/statefulset_test.yaml index 552bbf1c..e84acc6e 100644 --- a/charts/atlantis/tests/statefulset_test.yaml +++ b/charts/atlantis/tests/statefulset_test.yaml @@ -332,6 +332,7 @@ tests: value: name: gitconfig-volume secret: + defaultMode: 432 secretName: my-release-atlantis-gitconfig - equal: path: spec.template.spec.containers[0].volumeMounts[?(@.name == @@ -351,6 +352,7 @@ tests: value: name: gitconfig-volume secret: + defaultMode: 432 secretName: atlantis-gitconfig - equal: path: spec.template.spec.containers[0].volumeMounts[?(@.name ==