I have a nice setup with LDAP on my primary MX, which serves all my
needs in a very satisfying way. Now I want to deploy the secondary mx
with the same setup, with the same LDAP content (via a LDAP-slave).
and I want exim to first check if mailHost==$hostname. If it matches, it
should accept the mail and deliver it. If it does not match, it should
accept it, and send it to the host in mailHost.
Is this possible? Is there a variable containing the hostname, so I can
test against that? And can I use two conditions in an accept router?
(One to find the username of the receipent, and one to test if hostname
== mailHost). I could really, really need some help with that
condition...
If I ever get this to work, it doesn't matter which MX is first or last,
I can choose which mailserver that receives each account's mail. Really
hope I can get this to work :) I used to have this working with
sendmail, but I'm moving away from it for several reasons.