Skip to content

Commit 21f3ca8

Browse files
authored
make CLIENT_SECRET ref optional (#259)
* make CLIENT_SECRET ref optional * bump patch version * change toggle
1 parent e0eed81 commit 21f3ca8

File tree

8 files changed

+25
-1
lines changed

8 files changed

+25
-1
lines changed

charts/retool/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ apiVersion: v2
22
name: retool
33
description: A Helm chart for Kubernetes
44
type: application
5-
version: 6.8.6
5+
version: 6.8.7
66
maintainers:
77
- name: Retool Engineering
88

charts/retool/templates/_workers.tpl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,8 +175,10 @@ spec:
175175
{{- end }}
176176
- name: WORKFLOW_BACKEND_HOST
177177
value: http://{{ include "retool.workflowBackend.name" $ }}
178+
{{- if $.Values.config.auth.google.enabled }}
178179
- name: CLIENT_ID
179180
value: {{ default "" $.Values.config.auth.google.clientId }}
181+
{{- end }}
180182
- name: COOKIE_INSECURE
181183
value: {{ $.Values.config.useInsecureCookies | quote }}
182184
- name: POSTGRES_HOST
@@ -251,6 +253,7 @@ spec:
251253
key: postgresql-password
252254
{{- end }}
253255
{{- end }}
256+
{{- if $.Values.config.auth.google.enabled }}
254257
- name: CLIENT_SECRET
255258
valueFrom:
256259
secretKeyRef:
@@ -262,6 +265,7 @@ spec:
262265
key: google-client-secret
263266
{{- end }}
264267
{{- end }}
268+
{{- end }}
265269
{{- range $key, $value := $.Values.env }}
266270
- name: "{{ $key }}"
267271
value: "{{ $value }}"

charts/retool/templates/deployment_backend.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,10 @@ spec:
105105
- name: DISABLE_JAVA_DBCONNECTOR
106106
value: "true"
107107
{{ end }}
108+
{{- if .Values.config.auth.google.enabled }}
108109
- name: CLIENT_ID
109110
value: {{ default "" .Values.config.auth.google.clientId }}
111+
{{- end }}
110112
- name: COOKIE_INSECURE
111113
value: {{ .Values.config.useInsecureCookies | quote }}
112114
- name: POSTGRES_HOST
@@ -231,6 +233,7 @@ spec:
231233
key: postgresql-password
232234
{{- end }}
233235
{{- end }}
236+
{{- if .Values.config.auth.google.enabled }}
234237
- name: CLIENT_SECRET
235238
valueFrom:
236239
secretKeyRef:
@@ -242,6 +245,7 @@ spec:
242245
key: google-client-secret
243246
{{- end }}
244247
{{- end }}
248+
{{- end }}
245249
{{- range $key, $value := .Values.env }}
246250
- name: "{{ $key }}"
247251
value: "{{ $value }}"

charts/retool/templates/deployment_dbconnector.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,8 +88,10 @@ spec:
8888
value: "true"
8989
- name: WORKFLOW_BACKEND_HOST
9090
value: http://{{ template "retool.fullname" . }}-workflow-backend
91+
{{- if .Values.config.auth.google.enabled }}
9192
- name: CLIENT_ID
9293
value: {{ default "" .Values.config.auth.google.clientId }}
94+
{{- end }}
9395
- name: COOKIE_INSECURE
9496
value: {{ .Values.config.useInsecureCookies | quote }}
9597

@@ -150,6 +152,7 @@ spec:
150152
key: postgresql-password
151153
{{- end }}
152154
{{- end }}
155+
{{- if .Values.config.auth.google.enabled }}
153156
- name: CLIENT_SECRET
154157
valueFrom:
155158
secretKeyRef:
@@ -161,6 +164,7 @@ spec:
161164
key: google-client-secret
162165
{{- end }}
163166
{{- end }}
167+
{{- end }}
164168
{{- range $key, $value := .Values.env }}
165169
- name: "{{ $key }}"
166170
value: "{{ $value }}"

charts/retool/templates/deployment_jobs.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,10 @@ spec:
7474
value: production
7575
- name: SERVICE_TYPE
7676
value: JOBS_RUNNER
77+
{{- if .Values.config.auth.google.enabled }}
7778
- name: CLIENT_ID
7879
value: {{ default "" .Values.config.auth.google.clientId }}
80+
{{- end }}
7981
- name: COOKIE_INSECURE
8082
value: {{ .Values.config.useInsecureCookies | quote }}
8183
- name: POSTGRES_HOST
@@ -137,6 +139,7 @@ spec:
137139
key: postgresql-password
138140
{{- end }}
139141
{{- end }}
142+
{{- if .Values.config.auth.google.enabled }}
140143
- name: CLIENT_SECRET
141144
valueFrom:
142145
secretKeyRef:
@@ -148,6 +151,7 @@ spec:
148151
key: google-client-secret
149152
{{- end }}
150153
{{- end }}
154+
{{- end }}
151155
{{- range $key, $value := .Values.env }}
152156
- name: "{{ $key }}"
153157
value: "{{ $value }}"

charts/retool/templates/deployment_workflows.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,8 +148,10 @@ spec:
148148

149149
{{- include "retool.telemetry.includeEnvVars" . | nindent 10 }}
150150

151+
{{- if .Values.config.auth.google.enabled }}
151152
- name: CLIENT_ID
152153
value: {{ default "" .Values.config.auth.google.clientId }}
154+
{{- end }}
153155
- name: COOKIE_INSECURE
154156
value: {{ .Values.config.useInsecureCookies | quote }}
155157
- name: POSTGRES_HOST
@@ -212,6 +214,7 @@ spec:
212214
key: postgresql-password
213215
{{- end }}
214216
{{- end }}
217+
{{- if .Values.config.auth.google.enabled }}
215218
- name: CLIENT_SECRET
216219
valueFrom:
217220
secretKeyRef:
@@ -223,6 +226,7 @@ spec:
223226
key: google-client-secret
224227
{{- end }}
225228
{{- end }}
229+
{{- end }}
226230
{{- range $key, $value := .Values.env }}
227231
- name: "{{ $key }}"
228232
value: "{{ $value }}"

charts/retool/values.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ config:
1414
postgresPoolMaxSize: 10
1515
auth:
1616
google:
17+
# whether to populate CLIENT_ID and CLIENT_SECRET env vars (default: true for backwards compatibility)
18+
enabled: true
1719
clientId:
1820
clientSecret:
1921
# clientSecretSecretName is the name of the secret where the google client secret is stored (can be used instead of clientSecret)

values.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ config:
1414
postgresPoolMaxSize: 10
1515
auth:
1616
google:
17+
# whether to populate CLIENT_ID and CLIENT_SECRET env vars (default: true for backwards compatibility)
18+
enabled: true
1719
clientId:
1820
clientSecret:
1921
# clientSecretSecretName is the name of the secret where the google client secret is stored (can be used instead of clientSecret)

0 commit comments

Comments
 (0)