Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
80014450fa
|
@@ -1,29 +1,63 @@
|
|||||||
{{- if .Values.ingress.enabled -}}
|
{{- if .Values.ingress.enabled -}}
|
||||||
{{- $fullName := include "mailman3.fullname" . -}}
|
{{- $fullName := include "mailman3.fullname" . -}}
|
||||||
{{- $svcPort := .Values.service.port -}}
|
{{- $httpPort := .Values.service.port -}}
|
||||||
apiVersion: networking.k8s.io/v1
|
apiVersion: networking.k8s.io/v1
|
||||||
kind: Ingress
|
kind: Ingress
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ $fullName }}
|
name: {{ $fullName }}
|
||||||
|
namespace: {{ .Values.namespace | default .Release.Namespace }}
|
||||||
labels:
|
labels:
|
||||||
{{- include "mailman3.labels" . | nindent 4 }}
|
{{- include "mailman3.labels" . | nindent 4 }}
|
||||||
{{- with .Values.ingress.annotations }}
|
|
||||||
annotations:
|
annotations:
|
||||||
{{- toYaml . | nindent 4 }}
|
{{- range $key, $value := .Values.ingress.annotations }}
|
||||||
|
{{ $key }}: {{ $value | quote }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
spec:
|
spec:
|
||||||
{{- if .Values.ingress.tls }}
|
ingressClassName: {{ tpl .Values.ingress.className . }}
|
||||||
|
{{- if .Values.ingress.tls }}
|
||||||
tls:
|
tls:
|
||||||
|
{{- range .Values.ingress.tls }}
|
||||||
- hosts:
|
- hosts:
|
||||||
- {{ .Values.hostname }}
|
{{- range .hosts }}
|
||||||
secretName: {{ include "mailman3.fullname" . }}-certificate
|
- {{ tpl . $ | quote }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
secretName: {{ .secretName }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
rules:
|
rules:
|
||||||
- host: {{ .Values.hostname | quote }}
|
{{- range .Values.ingress.hosts }}
|
||||||
|
- host: {{ tpl .host $ | quote }}
|
||||||
http:
|
http:
|
||||||
paths:
|
paths:
|
||||||
- path: /
|
{{- if .paths }}
|
||||||
|
{{- range .paths }}
|
||||||
|
{{- if kindIs "string" . }}
|
||||||
|
- path: {{ . }}
|
||||||
|
pathType: {{ default "Prefix" $.Values.ingress.pathType }}
|
||||||
backend:
|
backend:
|
||||||
serviceName: {{ include "mailman3.fullname" . }}-web
|
service:
|
||||||
servicePort: 80
|
name: {{ $fullName }}-http
|
||||||
|
port:
|
||||||
|
number: {{ $httpPort }}
|
||||||
|
{{- else }}
|
||||||
|
- path: {{ .path | default "/" }}
|
||||||
|
pathType: {{ .pathType | default "Prefix" }}
|
||||||
|
backend:
|
||||||
|
service:
|
||||||
|
name: {{ $fullName }}-http
|
||||||
|
port:
|
||||||
|
number: {{ $httpPort }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
{{- else }}
|
||||||
|
- path: "/"
|
||||||
|
pathType: "Prefix"
|
||||||
|
backend:
|
||||||
|
service:
|
||||||
|
name: {{ $fullName }}-http
|
||||||
|
port:
|
||||||
|
number: {{ $httpPort }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
||||||
|
|||||||
@@ -70,9 +70,6 @@ service:
|
|||||||
|
|
||||||
ingress:
|
ingress:
|
||||||
enabled: false
|
enabled: false
|
||||||
tls: false
|
tls: []
|
||||||
annotations:
|
className: letsencrypt-prod
|
||||||
# use NGINX Ingress Controller
|
annotations: {}
|
||||||
#kubernetes.io/ingress.class: "nginx"
|
|
||||||
# use Cert-Manager for LetsEncrypt Certificates
|
|
||||||
#cert-manager.io/issuer: "letsencrypt-prod"
|
|
||||||
|
|||||||
Reference in New Issue
Block a user