On Sat, Oct 4, 2008 at 11:23 PM, Leonardo Tancredi
<[EMAIL PROTECTED]> wrote:

> [...] I've seen an old email where Wietse suggested using regexp
> maps, but I've no idea how that would be done in this case:
>
I found out how to do this, so this solves my problem. Here's how:

First a little change in main.cf...

--------
relayhost =
sender_dependent_relayhost_maps = pcre:/etc/postfix/sender_relay.pcre
--------

And here's the PCRE sender-dependent relayhost map with a wildcard
entry that sends all other mail through a different relayhost:

-------- begin /etc/postfix/sender_relay.pcre ----
/[EMAIL PROTECTED]/     [smtp.postoffice.net]
/[EMAIL PROTECTED]/     [smtp.postoffice.net]
/[EMAIL PROTECTED]/     [smtp.postoffice.net]
/[EMAIL PROTECTED]/  [smtp.postoffice.net]
/[EMAIL PROTECTED]/  [smtp.postoffice.net]
/./    [veriosmtp.net]
-------- end /etc/postfix/sender_relay.pcre ------

Anyway, my problems with the undue precedence of relayhost the over
sender-dependent relayhost map resulted to be transient, probably
related to a lack of postfix restart after changes to these maps.

Sorry for the noise,

LT

Reply via email to