From 70991c9cf24d8324de08c051db5c4d71c42cfef2 Mon Sep 17 00:00:00 2001 From: Fabio Date: Thu, 17 Nov 2022 11:31:02 -0300 Subject: [PATCH] Implemented LDAP option for emailleg --- .../emailleg/v1.4.0/templates/deployment.yaml | 17 ++++++++++++++++- charts/emailleg/v1.4.0/values.yaml | 4 ++++ 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/charts/emailleg/v1.4.0/templates/deployment.yaml b/charts/emailleg/v1.4.0/templates/deployment.yaml index 981b0a1..1f20bf3 100755 --- a/charts/emailleg/v1.4.0/templates/deployment.yaml +++ b/charts/emailleg/v1.4.0/templates/deployment.yaml @@ -44,6 +44,12 @@ spec: value: {{ .Values.mail.domain | quote }} - name: POSTMASTER value: "admin" + {{- if .Values.mail.ldap.server }} + - name: LDAP_SRV + value: {{ .Values.mail.ldap.server }} + - name: BASE_DN + value: {{ .Values.mail.ldap.baseDN }} + {{- end }} ports: - name: imap containerPort: 143 @@ -91,6 +97,14 @@ spec: value: {{ .Values.mail.relayNets | quote }} - name: RELAYHOST value: {{ .Values.mail.relayHost | quote }} + {{- if .Values.mail.ldap.server }} + - name: LDAP_SRV + value: {{ .Values.mail.ldap.server }} + - name: BASE_DN + value: {{ .Values.mail.ldap.baseDN }} + - name: MBOX_DOMAINS + value: {{ .Values.mail.ldap.mboxDomains }} + {{- end }} ports: - name: smtp containerPort: 25 @@ -114,6 +128,7 @@ spec: name: mailvol resources: {{- toYaml .Values.smtp.resources | nindent 12 }} + {{- if not .Values.mail.ldap.server }} - name: admin securityContext: {{- toYaml .Values.securityContext | nindent 12 }} @@ -186,7 +201,7 @@ spec: name: mailvol resources: {{- toYaml .Values.redis.resources | nindent 12 }} - + {{- end }} volumes: - name: mailvol persistentVolumeClaim: diff --git a/charts/emailleg/v1.4.0/values.yaml b/charts/emailleg/v1.4.0/values.yaml index 2aa3408..2b87ff6 100755 --- a/charts/emailleg/v1.4.0/values.yaml +++ b/charts/emailleg/v1.4.0/values.yaml @@ -75,6 +75,10 @@ mail: website: http://www.interlegis.leg.br siteName: E-mail Legislativo managerPW: secretPw + ldap: + server: "" + baseDN: "" + mboxDomains: "" persistence: #storageClass: ""