Re: [Exim] Router question

Top Page
Delete this message
Reply to this message
Author: Torsten Luettgert
Date:  
To: Johann Spies via COM.BOX TEMA
CC: exim-users
Subject: Re: [Exim] Router question
On Don, 2003-07-31 at 15:54, Johann Spies via COM.BOX TEMA wrote:
> I want to test Spamassassin and want to relay the mail of individual
> users to a test machine with Spamassassin. I am not sure how to do
> it. I don't want to rewrite the headers and have tried the following
> routers which do not work:
>
> ========================
> spam_exchange_router:
>    driver = manualroute
>    transport = remote_smtp
>    route_list = jspies@??? pikkewyn.sun.ac.za

>
> spam_router:
>    driver = manualroute
>    transport = remote_smtp
>    route_list = jspies@??? pikkewyn.sun.ac.za

>
> relayrouter:
> driver = manualroute
> domains = ! +local_domains
> route_data = ${lookup pgsql {select distinct route from
> smtprelayhosts2 where host = '$domain' limit 1}}
> transport = remote_smtp
> ==========================
>
> > exim -bt jspies@???
> jspies@???
>     <-- jspies@???
>   router = relayrouter, transport = remote_smtp
>   host stbbh.stb.sun.ac.za [146.232.20.30]

>
> What is the correct way to do it?


spam_test_router:
    driver = manualroute
    domains = sun.ac.za
    local_parts = jspies
    transport = remote_smtp
    route_list = * spamtester.ac.za byname
    no_more


this will redirect mail to jspies@??? to the machine
spamtester.ac.za.
If you want to redirect multiple users, replace the local_parts
condition by a lookup, e.g.

    local_parts = lsearch;/etc/spamtestees


- Torsten