Skip to content

Commit

Permalink
Refactor environment variables
Browse files Browse the repository at this point in the history
Environment variables are loaded by envFrom instead writing them in a Pod spec.

In secret object the keys has been uppercased to easly load them and the postgres url has been put there.
  • Loading branch information
mjasion committed Jan 13, 2023
1 parent 10ef5e4 commit ae36811
Show file tree
Hide file tree
Showing 11 changed files with 190 additions and 383 deletions.
293 changes: 0 additions & 293 deletions charts/studio/templates/_env_vars.tpl

This file was deleted.

5 changes: 5 additions & 0 deletions charts/studio/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -118,3 +118,8 @@ Create the name of the service account to use
{{- default "default" .Values.serviceAccount.name }}
{{- end }}
{{- end }}

{{- define "studio.checkSum" }}
checksum/studio-cm: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }}
checksum/studio-ca-certificates-cm: {{ include (print $.Template.BasePath "/configmap-ca-cert.yaml") . | sha256sum }}
{{- end}}
9 changes: 9 additions & 0 deletions charts/studio/templates/configmap-ca-cert.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: studio-ca-certificates
data:
{{- if .Values.global.customCaCert }}
self_signed_ca.crt: |
{{ .Values.global.customCaCert | indent 4}}
{{- end }}
Loading

0 comments on commit ae36811

Please sign in to comment.