Add support for sender rewriting using postsrsd
With SRS we support forwarding of mails without (fully) breaking SPF alignment.
This commit is contained in:
@@ -261,6 +261,24 @@ in
|
||||
configurePostfix = true;
|
||||
};
|
||||
|
||||
# Sender Rewriting Scheme (https://www.libsrs2.net/srs/srs.pdf)
|
||||
services.postsrsd = {
|
||||
inherit (cfg.srs) enable;
|
||||
configurePostfix = true;
|
||||
settings = {
|
||||
domains = lib.unique (
|
||||
[
|
||||
cfg.fqdn
|
||||
cfg.sendingFqdn
|
||||
cfg.systemDomain
|
||||
]
|
||||
++ cfg.domains
|
||||
);
|
||||
separator = "=";
|
||||
srs-domain = cfg.srs.domain;
|
||||
};
|
||||
};
|
||||
|
||||
systemd.services.postfix-setup = lib.mkIf cfg.ldap.enable {
|
||||
preStart = ''
|
||||
${appendPwdInVirtualMailboxMap}
|
||||
|
||||
Reference in New Issue
Block a user