On 25 June 2012 09:23, James B. Byrne <byrn...@harte-lyne.ca> wrote:
>
> On Mon, June 25, 2012 11:50, Simon Brereton wrote:
>> On 22 June 2012 16:57, Wietse Venema <wie...@porcupine.org> wrote:
>>> Simon Brereton:
>>>> I would like to use an alias file that routes any of
>>>> postmas...@example.net, postmas...@example.com,
>>>> postmas...@example.info, postmas...@example.org, etc (and also
>>>> abuse@)
>>>> to postmas...@example.com without having to have the mailbox
>>>> created
>>>> in the Accounts table as I currently do.  Since any replies to
>>>> these
>>>> emails would be sent from the .com domain only that mailbox and
>>>> that
>>>> entry needs to exist in the Accounts table.
>>>>
>>>> What is the best way to do this?
>
> Have you considered using a regexp style virtual_aliases map?
> Something like: regexp:/etc/postfix/virtual_alaises_regexp
>
> that contains something along the lines of:
>
> /^abuse@example\.[:alpha:]{2,4}$/             postmas...@example.com
> /^postmaster@example\.[:alpha:]{2,4}$/        postmas...@example.com
>
> These regexp are not tested so I doubt that they would work exactly as
> shown but, you get the idea.  Note that in this case you absolutely
> MUST have postmas...@example.com mapped to a local delivery mailbox or
> aliased to something that will not match the left hand side of the
> regexp map.  Otherwise I suspect that you will get a loop.

Thanks James

I'll play around with that and see where I get to.

Simon

Reply via email to