diff --git a/helm/mail/templates/configmap.yaml b/helm/mail/templates/configmap.yaml index 3624d2e..b7446fd 100644 --- a/helm/mail/templates/configmap.yaml +++ b/helm/mail/templates/configmap.yaml @@ -16,7 +16,7 @@ data: {{- range $key, $value := .Values.config.opendkim }} OPENDKIM_{{ $key }}: {{ $value | quote }} {{- end }} - {{- if .Values.certs.create }} + {{- if or .Values.certs.create .Values.certs.existingSecret }} _enable_tls.sh: | #!/usr/bin/env bash set -e diff --git a/helm/mail/templates/statefulset.yaml b/helm/mail/templates/statefulset.yaml index 7e9003b..a7bed4e 100644 --- a/helm/mail/templates/statefulset.yaml +++ b/helm/mail/templates/statefulset.yaml @@ -188,7 +188,7 @@ spec: volumes: - name: tmp emptyDir: {} - {{- if .Values.certs.create }} + {{- if or .Values.certs.create .Values.certs.existingSecret }} - name: certs-init configMap: name: {{ $fullName }} diff --git a/helm/test_16_certs_existing_secret.yml b/helm/test_16_certs_existing_secret.yml index a475cbf..e13658e 100644 --- a/helm/test_16_certs_existing_secret.yml +++ b/helm/test_16_certs_existing_secret.yml @@ -1,3 +1,3 @@ certs: - create: true + create: false existingSecret: "controller-generated-secret"