From 7ef5561d5481f4070230fac0ec3de25792029fed Mon Sep 17 00:00:00 2001 From: Andy Date: Sat, 27 Apr 2019 02:46:29 +0800 Subject: [PATCH] [stable/atlantis] Pass server configurations via environment variable (#13321) * [stable/atlantis] pass flags as environment variable Signed-off-by: Andy Aldo Dharmawan * [stable/atlantis] Bump chart version (MINOR) Signed-off-by: Andy Aldo Dharmawan * [stable/atlantis] Update README.md Add notes to indicate that server configurations are passed via environment variables Signed-off-by: Andy Aldo Dharmawan --- stable/atlantis/Chart.yaml | 2 +- stable/atlantis/README.md | 2 ++ stable/atlantis/templates/statefulset.yaml | 14 ++++++++------ 3 files changed, 11 insertions(+), 7 deletions(-) diff --git a/stable/atlantis/Chart.yaml b/stable/atlantis/Chart.yaml index ab9db22eef..055c1e55a7 100644 --- a/stable/atlantis/Chart.yaml +++ b/stable/atlantis/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v1 appVersion: "v0.7.1" description: A Helm chart for Atlantis https://www.runatlantis.io name: atlantis -version: 3.1.0 +version: 3.2.0 keywords: - terraform home: https://www.runatlantis.io diff --git a/stable/atlantis/README.md b/stable/atlantis/README.md index 883f3db494..fed41bcf48 100644 --- a/stable/atlantis/README.md +++ b/stable/atlantis/README.md @@ -62,6 +62,8 @@ The following options are supported. See [values.yaml](values.yaml) for more de | `ingress.host` | Domain name Kubernetes Ingress rule looks for. Set it to the domain Atlantis will be hosted on. | `chart-example.local` | | `ingress.tls` | Kubernetes tls block. See [Kubernetes docs](https://kubernetes.io/docs/concepts/services-networking/ingress/#tls) for details. | `[]` | +**NOTE**: All the [Server Configurations](https://www.runatlantis.io/docs/server-configuration.html) are passed as [Environment Variables](https://www.runatlantis.io/docs/server-configuration.html#environment-variables). + ## Upgrading ### From 2.* to 3.* diff --git a/stable/atlantis/templates/statefulset.yaml b/stable/atlantis/templates/statefulset.yaml index a28c4997b0..7078c73ef0 100644 --- a/stable/atlantis/templates/statefulset.yaml +++ b/stable/atlantis/templates/statefulset.yaml @@ -74,12 +74,6 @@ spec: {{- end}} args: - server - {{- if .Values.allowForkPRs }} - - --allow-fork-prs - {{- end }} - {{- if .Values.defaultTFVersion }} - - --default-tf-version={{ .Values.defaultTFVersion }} - {{- end }} ports: - name: atlantis containerPort: 4141 @@ -88,6 +82,14 @@ spec: - name: {{ $key }} value: {{ $value | quote }} {{- end }} + {{- if .Values.allowForkPRs }} + - name: ATLANTIS_ALLOW_FORK_PRS + value: {{ .Values.allowForkPRS }} + {{- end }} + {{- if .Values.defaultTFVersion }} + - name: ATLANTIS_DEFAULT_TF_VERSION + value: {{ .Values.defaultTFVersion }} + {{- end }} {{- if .Values.logLevel }} - name: ATLANTIS_LOG_LEVEL value: {{ .Values.logLevel | quote}}