On Mon, Dec 10, 2012 at 12:39 PM, John Burnham <[email protected] > wrote:
> > > > I've been using Postfix for many years and I've recently migrated some of > > my servers to Exim. > > In Postfix I've been using transport_maps to specify where a specific > > domain or email-address should go. > > > > In some cases I have a couple of users that are not on the same server as > > the rest of the domain. So I've done something like this: > > > > domain.com smtp:[mail.domain.com] > > [email protected] smtp:[other.server.domain.com] > > > > > > How would I achieve this in Exim? > > I haven't done any actual configuration on this Exim-server myself so I > > don't really know where to look. > > > > > > You mean you want to pass the mail on to another SMTP server ? In that > case, what you're probably looking for is the manualroute router. It is > documented at > > > http://www.exim.org/exim-html-current/doc/html/spec_html/ch-the_manualroute_router.html > > which has some reasonable examples. > > For your above example you could have something like: > > test_route: > driver = manualroute > domains = domain.com > local_parts = !user1 > transport = remote_smtp > route_list = domain.com mail.domain.com > > test_route2: > driver = manualroute > domains = domain.com > local_parts = user1 > transport = remote_smtp > route_list = domain.com other.server.domain.com > > in your routers. Remember that routers are traversed in the order they're > encountered in your config file. > > You can, of course, use lookups or files to make it more general. > (local_parts = dbm; /etc/exim/$domain/list.of.local.parts). Some of this is > clarified in > > > http://www.exim.org/exim-html-current/doc/html/spec_html/ch-generic_options_for_routers.html > > Have a look at the docs and if you want any clarification, please ask. Thanks for the reply. I found this where it looks in a file where I have specified the transport for each domain, I'm wondering if it's possible to add a second file to this, 'emailaddress.list' for example, where I will specify which route a specific email-address should take if it's not going to the standard server. filter_forward: driver = manualroute transport = remote_smtp domains = !@ : +relay_to_domains route_data = ${lookup{$domain}wildlsearch{VARDIR/spool/tmp/mailcleaner/domains.list}} hosts_randomize = true headers_remove = X-MailCleaner-Bounce headers_add = X-MailCleaner-ReportURL: __REPORT_URL__ For example, it it possible to do something like this: filter_forward: driver = manualroute transport = remote_smtp domains = !@ : +relay_to_domains route_data = ${lookup{$domain}wildlsearch{VARDIR/spool/tmp/mailcleaner/domains.list}}${lookup{$domain}wildlsearch{VARDIR/spool/tmp/mailcleaner/emailaddress.list}} hosts_randomize = true headers_remove = X-MailCleaner-Bounce headers_add = X-MailCleaner-ReportURL: __REPORT_URL__ Thanks, -Patric -- ## List details at https://lists.exim.org/mailman/listinfo/exim-users ## Exim details at http://www.exim.org/ ## Please use the Wiki with this list - http://wiki.exim.org/
