[Exim] Changing the order of routers

Top Page
Delete this message
Reply to this message
Author: Alan Chandler
Date:  
To: exim-users
Subject: [Exim] Changing the order of routers
I am struggling with how to achieve what I want with exim4, something I could
do with exim3.

I have a small set of local users (4 in total) that I accept mail for. For
any other local addresses (not redirected via an alias file - router futher
up the config file) I want to reject the mail.

I also want to arrange that local user addresses with a suffix of "outside"
get rerouted externally after being redirected to be of a form that looks
like the normal incoming local mail. (Its a good way of testing my
configuration)

In order to achieve this, I need a set of routers approx like the following
(taken from the conversion programme between the two versions)

forceoutside:
driver = redirect
data = $local_part@???
local_part_suffix = -outside
local_parts = CONFDIR/local-users
redirect_router = forceoutside_part2
retry_use_local_part

localuser:
driver = accept
local_parts = CONFDIR/local-users
retry_use_local_part
transport = local_delivery
user = ${lc:$local_part}

allelse:
FAIL ALL MESSAGES THAT GET THIS FAR SO THE forceoutside_part2 IS NEVER
TRAVERSED

forceoutside_part2:
driver = accept
transport = outside_smtp


I am struggling with whether I need an allelse router - could I just change
the localuser router to somehow fail if CONFDIR/local-users doesn't match the
local part, or if I need the allesle router how do I do it. The
specification refers to routers failing, declining, passing etc but I don't
really understand how to make them do it.



--
Alan Chandler
alan@???