Re: [Exim] Exim as frontend relay

Startseite
Nachricht löschen
Nachricht beantworten
Autor: Tim Jackson
Datum:  
To: exim-users
Betreff: Re: [Exim] Exim as frontend relay
Hi MiikaT, on Mon, 9 Feb 2004 13:11:53 +0200 you wrote:

> can I configure exim to route/relay all incoming mail to backend
> mailserver, based on domain suffix? The backend mailserver is not listed
> in public dns mx records.


Yes, use the "manualroute" driver. Here's a quick & simple example:

manualroute_domains:
driver = manualroute
domains = lsearch;/etc/exim/manualroute
route_data = ${lookup{$domain}lsearch{/etc/exim/manualroute}}
transport = remote_smtp
no_more

This example expects a file /etc/exim/manualroute with a list of domains
that you want routed, along with the servers to route them to
(colon-separated), e.g.:

some.domain:        my.internal.server
some.other.domain:  foo.bar.server : fallback.server : 192.168.0.1


That would route messages for "some.domain" to "my.internal.server" etc.

This is OK for a small, fixed list of domains. If you have a lot of
domains and therefore really need to generalise based on a domain suffix
(as you implied) then you can adjust the database lookups (lsearch in this
case, but you could easily make it dbm/MySQL/whatever) to suit your needs.

Tim