mailu/postfix.cf.tmpl

22 lines
1.1 KiB
Cheetah

{{ if eq (env "MAILMAN_POSTFIX_OVERRIDES") "1" }}
# https://github.com/maxking/docker-mailman#setting-up-your-mta
# https://mailu.io/1.7/faq.html?highlight=override#how-can-i-override-settings
# https://github.com/Mailu/Mailu/blob/master/core/postfix/conf/main.cf
# Please note, this config assumes "recipient_delimiter = +" in the main.cf
# and transport_maps/relay_domains preserve the overriden postfix.cf config values
# and finally, we use single lines configuration definitions because:
# https://github.com/Mailu/Mailu/pull/1806/files#diff-55df9d2f8b8d40391d9d451a1e8155292465d48c52e78dd34655be834cd3dc9fR264-R266
unknown_local_recipient_reject_code = 550
owner_request_special = no
virtual_mailbox_maps = regexp:/opt/mailman/var/data/postfix_lmtp, \${podop}mailbox
transport_maps = regexp:/opt/mailman/var/data/postfix_lmtp \${podop}transport
local_recipient_maps = regexp:/opt/mailman/var/data/postfix_lmtp
{{ end }}
{{ if eq (env "SENDER_LOGINS_POSTFIX_OVERRIDES") "1" }}
# https://github.com/Mailu/Mailu/issues/1096
smtpd_sender_login_maps = pcre:/overrides/sender_logins \${podop}senderlogin
{{ end }}