mail_relay: postfix relays all mail through the mailcow submission port with a mailbox per host, replaces mail_aliases

This commit is contained in:
2026-10-26 09:44:37 +00:00
parent c91c56b153
commit 885e6f3338
7 changed files with 235 additions and 29 deletions
+18
View File
@@ -0,0 +1,18 @@
---
# Every host sends its mail through the mailcow submission port with its own mailbox
# (doc/host-mail-relay.md in the kubernetes repo). The password is set in host_vars.
mail_relay:
host: tranio.ruekov.eu
port: 587
# SASL login of the mailcow mailbox; the password is an SMTP-only app password of it.
username: "{{ inventory_hostname_short }}.system@mail.ruekov.eu"
# Sender address every local address is rewritten to; mailcow accepts only addresses of the login.
sender: "{{ mail_relay.username }}"
password: ""
# Root mail goes to this address: /etc/aliases and, on Proxmox hosts, the email of root@pam.
root_mail: admin@ruekov.eu
myhostname: "{{ inventory_hostname }}"
# The local postfix only takes mail from the host itself.
inet_interfaces: loopback-only
# The smtp inet service of master.cf; off where another daemon holds port 25 (tranio: mailcow).
smtpd_listener: true