feat: update traefik field for multiple hosts
This commit is contained in:
parent
6060312074
commit
fc8252ee23
@ -41,6 +41,7 @@ Helm Chart for Stalwart Mail Server - Secure & Modern All-in-One Mail Server (IM
|
||||
| service.ports.submission | int | `587` | |
|
||||
| service.type | string | `"NodePort"` | |
|
||||
| traefik.enabled | bool | `false` | |
|
||||
| traefik.hosts | list | `[]` | |
|
||||
| traefik.ports.http | string | `"websecure"` | |
|
||||
| traefik.ports.imaps | string | `"imaps"` | |
|
||||
| traefik.ports.smtps | string | `"smtps"` | |
|
||||
|
@ -1,5 +1,5 @@
|
||||
{{- if .Values.traefik.enabled }}
|
||||
{{- range $port,$entryport := .Values.traefik.ports }}
|
||||
{{- range $port, $entryport := .Values.traefik.ports }}
|
||||
---
|
||||
apiVersion: traefik.io/v1alpha1
|
||||
kind: IngressRouteTCP
|
||||
@ -9,13 +9,15 @@ spec:
|
||||
entryPoints:
|
||||
- {{ $entryport }}
|
||||
routes:
|
||||
- match: HostSNI(`{{ $.Values.traefik.host }}`)
|
||||
{{- range $host := .Values.traefik.hosts }}
|
||||
- match: HostSNI(`{{ $host }}`)
|
||||
services:
|
||||
- name: {{ include "stalwart-mail.fullname" $ }}
|
||||
port: {{ $port }}
|
||||
proxyProtocol:
|
||||
version: 2
|
||||
{{- end }}
|
||||
tls:
|
||||
passthrough: true
|
||||
{{- end }}
|
||||
{{- end }}{{/* end-if .enabled */}}
|
||||
{{- end }}
|
||||
|
@ -34,7 +34,7 @@ ingress:
|
||||
|
||||
traefik:
|
||||
enabled: false
|
||||
#host: "mail.example.com"
|
||||
hosts: []
|
||||
ports:
|
||||
http: websecure
|
||||
imaps: imaps
|
||||
|
Loading…
Reference in New Issue
Block a user