[exim] How to choose the outgoing IPs for an E-Mail

Top Page

Reply to this message
Author: Luca Bertoncello
To: Exim Users ML
Subject: [exim] How to choose the outgoing IPs for an E-Mail
Hi, List!

I'd like to have a file such this:

lucabert.de: ips=<; ; 2001:1608:10:24:1::1
other.domain.tld: ips=<; ; 2001:1608:10:24:300::1
v4.domain.tld: ips=

and having the given IPs be used to send E-Mails from these domains...

I think, I have to use this file in the transports, and I tried this:

driver = smtp
helo_data = $smtp_active_hostname
interface =
${extract{ips}{${lookup{$sender_address_domain}lsearch{/etc/exim/mailouts}{<; ; 2001:1608:10:24:1::1}}}}

Unfortunately, it does not work...
It will always used an IP I didn't give in any configuration...

Could someone help me?
Of course, I need to have a default, if the $sender_address_domain does not
have an entry in /etc/exim/mailouts.

Thanks for any help!
Luca Bertoncello