Mail From Remote Server

Mail from Remote Server

ZeroTier solved one problem very easily. I have a mail server with spf records configured to specifically allow email from that server. The problem with this was that email from Raspberry Pis and whatnot would have problems being delivered.

Solution

With the originating server and the domain email server being joined to the same ZeroTier network, it was a simple matter of configuring the originating server to use the domain mail server as a smarthost. So assuming the originating server is running Exim4 on Debian, one would enter in ‘/etc/exim4/update-exim4.conf.conf’ the following.

dc_eximconfig_configtype='smarthost'
dc_smarthost='IP_OF_DOMAIN_MAIL_SERVER_IN_ZT'

On the domain mail server one simply adds the same ZeroTier network as an allowed local network in Postfix or whatever one is using. After restarting email services on both the originating server and the domain mail server everything just works.