Re: [Exim] Aliasfile director

Top Page
Delete this message
Reply to this message
Author: Philip Hazel
Date:  
To: David Robb
CC: exim-users
Subject: Re: [Exim] Aliasfile director
On Wed, 1 Mar 2000, David Robb wrote:

> How will this work when I'm trying to do the following? :
>
> bob@???: acme1@???
> jane@???: acme2@???
> *@acme.com: acme3@???
>
> bob and jane work fine, but *@acme.com still suffers from the current
> problem. If I were to move acme.com to a seperate transport/director pair,
> won't it break?


No. If you remove *@acme.com then any address that isn't bob or jane
will not be handled by the aliasing director, and will pass through to
the next director, which you can set up to handle the default case.

If you have a file that contains the defaults in this form

acme.com: acme3
emca.com: emca5
...

then you could use something like this (not tested, off the top of my
head)

# Transport

default_transport:
driver = smtp
hosts = ${local_part}@${length_1:$local_part}.pop.ihug.co.nz

# Director

defaults:
driver= smartuser
domains = lsearch;/that/file
transport = default_transport
new_address = ${lookup{$domain}lsearch{/that/file}{$value}}@???

The double lookup won't be as expensive as it looks because of the 
caching.    


-- 
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.