Use postfix options for routing mails through tunnel #45
|
@ -1260,8 +1260,25 @@ in
|
||||||
enablePop3 = true;
|
enablePop3 = true;
|
||||||
enablePop3Ssl = true;
|
enablePop3Ssl = true;
|
||||||
certificateScheme = "acme-nginx";
|
certificateScheme = "acme-nginx";
|
||||||
policydSPFExtraConfig = "skip_addresses = 5.78.86.156,2a01:4ff:1f0:83de::1";
|
|
||||||
} // (import /etc/nixos/secret/email_settings.nix);
|
} // (import /etc/nixos/secret/email_settings.nix);
|
||||||
|
services.postfix = {
|
||||||
|
mapFiles.sender_transport = pkgs.writeText "sender_transport" ''
|
||||||
|
@m-labs-intl.com intltunnel:
|
||||||
|
'';
|
||||||
|
config = {
|
||||||
|
sender_dependent_default_transport_maps = "hash:/var/lib/postfix/conf/sender_transport";
|
||||||
|
};
|
||||||
|
masterConfig."intltunnel" = {
|
||||||
|
type = "unix";
|
||||||
|
command = "smtp";
|
||||||
|
args = [
|
||||||
|
"-o" "inet_interfaces=10.47.3.1"
|
||||||
|
"-o" "smtp_helo_name=mail.m-labs-intl.com"
|
||||||
|
"-o" "inet_protocols=ipv4"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
services.roundcube = {
|
services.roundcube = {
|
||||||
enable = true;
|
enable = true;
|
||||||
hostName = "mail.m-labs.hk";
|
hostName = "mail.m-labs.hk";
|
||||||
|
|
Loading…
Reference in New Issue