From 5b2f6fbb4054494b317158009dcdf57aec315014 Mon Sep 17 00:00:00 2001 From: ihiverlet <94982379+ihiverlet@users.noreply.github.com> Date: Mon, 15 Jan 2024 16:56:32 +0100 Subject: [PATCH] =?UTF-8?q?add=20the=20name=20of=20a=20cert-manager=20Clus?= =?UTF-8?q?terIssuer=20to=20acquire=20a=20certificate=E2=80=A6=20(#118)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit add the name of a cert-manager ClusterIssuer to acquire a certificate for ingress --- charts/library-chart/Chart.yaml | 2 +- charts/library-chart/templates/_ingress.tpl | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/charts/library-chart/Chart.yaml b/charts/library-chart/Chart.yaml index 9f582ad5..ef8c16f2 100644 --- a/charts/library-chart/Chart.yaml +++ b/charts/library-chart/Chart.yaml @@ -1,4 +1,4 @@ apiVersion: v2 name: library-chart -version: 1.5.17 +version: 1.5.18 type: library diff --git a/charts/library-chart/templates/_ingress.tpl b/charts/library-chart/templates/_ingress.tpl index b8104258..a8cf35c1 100644 --- a/charts/library-chart/templates/_ingress.tpl +++ b/charts/library-chart/templates/_ingress.tpl @@ -21,6 +21,10 @@ Usage: {{- if .Values.security.allowlist.enabled }} nginx.ingress.kubernetes.io/whitelist-source-range: {{ .Values.security.allowlist.ip }} {{- end }} +{{- if .Values.ingress.useCertManager }} +cert-manager.io/cluster-issuer: {{ .Values.ingress.certManagerClusterIssuer }} +acme.cert-manager.io/http01-ingress-class: {{ .Values.ingress.ingressClassName }} +{{- end }} {{- end }} {{/* Ingress hostname */}} @@ -53,6 +57,9 @@ spec: tls: - hosts: - {{ .Values.ingress.hostname | quote }} + {{- if .Values.ingress.useCertManager }} + secretName: tls-cert-{{ include "library-chart.fullname" . }} + {{- end }} {{- end }} rules: - host: {{ .Values.ingress.hostname | quote }}