56 lines
1.1 KiB
YAML
56 lines
1.1 KiB
YAML
---
|
|
# Internal service - postfix connects here to deliver inbound mail
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: stalwart
|
|
namespace: stalwart
|
|
spec:
|
|
selector:
|
|
app: stalwart
|
|
ports:
|
|
- name: smtp-relay
|
|
port: 25
|
|
targetPort: 25
|
|
protocol: TCP
|
|
- name: http-internal
|
|
port: 8080
|
|
targetPort: 8080
|
|
protocol: TCP
|
|
- name: metrics
|
|
port: 9090
|
|
targetPort: 9090
|
|
protocol: TCP
|
|
---
|
|
# External LoadBalancer for user-facing mail services
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: stalwart-external
|
|
namespace: stalwart
|
|
annotations:
|
|
external-dns.alpha.kubernetes.io/hostname: mail.main.unkin.net
|
|
purelb.io/service-group: dmz
|
|
spec:
|
|
type: LoadBalancer
|
|
externalTrafficPolicy: Local
|
|
selector:
|
|
app: stalwart
|
|
ports:
|
|
- name: submission
|
|
port: 587
|
|
targetPort: 587
|
|
protocol: TCP
|
|
- name: imap
|
|
port: 143
|
|
targetPort: 143
|
|
protocol: TCP
|
|
- name: imaps
|
|
port: 993
|
|
targetPort: 993
|
|
protocol: TCP
|
|
- name: https
|
|
port: 443
|
|
targetPort: 443
|
|
protocol: TCP
|