Merge postfix configurations and use conditionals
This commit is contained in:
22
postfix.cf
Normal file
22
postfix.cf
Normal file
@ -0,0 +1,22 @@
|
||||
# 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
|
||||
|
||||
{{ if eq (env "MAILMAN_POSTFIX_OVERRIDES") "1" }}
|
||||
# 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
|
||||
transport_maps = regexp:/opt/mailman/var/data/postfix_lmtp \${podop}transport
|
||||
local_recipient_maps = regexp:/opt/mailman/var/data/postfix_lmtp
|
||||
relay_domains = regexp:/opt/mailman/var/data/postfix_domains \${podop}transport
|
||||
{{ end }}
|
||||
|
||||
{{ if eq (env "SENDER_LOGINS_POSTFIX_OVERRIDES") "1" }}
|
||||
# https://github.com/Mailu/Mailu/issues/1096
|
||||
|
||||
smtpd_sender_login_maps = unionmap:{${podop}senderlogin, pcre:/overrides/sender_logins}
|
||||
{{ end }}
|
||||
Reference in New Issue
Block a user