Mail Proxy for two domains nehind NAT

entpneur nginx-forum at forum.nginx.org
Mon Feb 12 01:57:04 UTC 2018


Hello,

I tried to setup NGiNX as a Mail Proxy for two domains behind NAT.  Users
will be diverted to the right server base on domain (eg./ user at domainA.com
will be diverted to Server A and user at domainB.com will be diverted to Server
B).

When I test the nginx.conf it gives me the following:

"nginx: [emerg] duplicate "0.0.0.0:143" address and port pair ..."

After some digging, I know that the listen directive need to have different
address:port pair but reuseport option is not allow in mail context. 

Is there a way to overcome or achieve that?  Please Help!  TIA!


Regards,
YSC

Posted at Nginx Forum: https://forum.nginx.org/read.php?2,278489,278489#msg-278489



More information about the nginx mailing list