diff --git a/kubernetes/chart/zulip/README.md b/kubernetes/chart/zulip/README.md index 3364323ab8..ebe8a8d65f 100644 --- a/kubernetes/chart/zulip/README.md +++ b/kubernetes/chart/zulip/README.md @@ -143,6 +143,17 @@ are defined in the `values.yaml` under `zulip.environment`. These environment variables are forwarded to the Docker container, you can read more about configuring Zulip through environment variables [here](https://github.com/zulip/docker-zulip/#configuration). +Variables can be either a plain scalar value ie. string/int or a projected value +from a secret or configmap, eg: + +```yaml +SETTING_EXTERNAL_HOST: zulip.example.com +SECRETS_email_password: + valueFrom: + secretKeyRef: + name: email + key: password +``` ### Dependencies diff --git a/kubernetes/chart/zulip/templates/_helpers.tpl b/kubernetes/chart/zulip/templates/_helpers.tpl index 39cd659d0b..a6fbde30a8 100644 --- a/kubernetes/chart/zulip/templates/_helpers.tpl +++ b/kubernetes/chart/zulip/templates/_helpers.tpl @@ -90,6 +90,10 @@ include all env variables for Zulip pods value: "{{ .Values.zulip.password }}" {{- range $key, $value := .Values.zulip.environment }} - name: {{ $key }} + {{- if kindIs "map" $value }} + {{- toYaml $value | nindent 2 }} + {{- else }} value: {{ $value | quote }} + {{- end }} {{- end }} {{- end }}