Compare commits
2 commits
7250fd4ee3
...
b5cc15a319
Author | SHA1 | Date | |
---|---|---|---|
Micke Nordin | b5cc15a319 | ||
Micke Nordin | 6217109290 |
|
@ -39,6 +39,18 @@ data:
|
||||||
{{- end }}
|
{{- end }}
|
||||||
PROMETHEUS_MULTIPROC_DIR: "/tmp"
|
PROMETHEUS_MULTIPROC_DIR: "/tmp"
|
||||||
---
|
---
|
||||||
|
{{- range $domain := $domains }}
|
||||||
|
{{- $name := $domain.name -}}
|
||||||
|
{{- $upper_name := $name | upper | replace "." "_" -}}
|
||||||
|
{{- $client_id := printf "%s_%s" $upper_name "OAUTH_CLIENT_ID" }}
|
||||||
|
{{- $client_secret := printf "%s_%s" $upper_name "OAUTH_CLIENT_SECRET" }}
|
||||||
|
{{- if hasKey $.Values.environment $client_id }}
|
||||||
|
{{ set $domain "OAUTH_CLIENT_ID" (get $.Values.environment $client_id) }}
|
||||||
|
{{- end }}
|
||||||
|
{{- if hasKey $.Values.environment $client_secret }}
|
||||||
|
{{ set $domain "OAUTH_CLIENT_SECRET" (get $.Values.environment $client_secret) }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: ConfigMap
|
kind: ConfigMap
|
||||||
metadata:
|
metadata:
|
||||||
|
|
|
@ -35,6 +35,26 @@ spec:
|
||||||
mountPath: /srv/domains.json
|
mountPath: /srv/domains.json
|
||||||
subPath: domains.json
|
subPath: domains.json
|
||||||
readOnly: true
|
readOnly: true
|
||||||
|
{{- if.Values.global.domains }}
|
||||||
|
env:
|
||||||
|
{{- range $domain := .Values.global.domains }}
|
||||||
|
{{- $name := $domain.name -}}
|
||||||
|
{{- $upper_name := upper $name | replace "." "_" -}}
|
||||||
|
{{- $lower_name := lower $name | replace "." "-" -}}
|
||||||
|
{{- $client_id := printf "%s_%s" $upper_name "OAUTH_CLIENT_ID" }}
|
||||||
|
{{- $client_secret := printf "%s_%s" $upper_name "OAUTH_CLIENT_SECRET" }}
|
||||||
|
- name: {{ $client_id }}
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: layer1-port-owncloud-{{ $lower_name }}
|
||||||
|
key: oauth-client-id
|
||||||
|
- name: {{ $client_secret }}
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: layer1-port-owncloud-{{ $lower_name }}
|
||||||
|
key: oauth-client-secret
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
envFrom:
|
envFrom:
|
||||||
- configMapRef:
|
- configMapRef:
|
||||||
name: mservice
|
name: mservice
|
||||||
|
|
Loading…
Reference in a new issue