Selective Forwarding with Postfix

I have set up a number of different ways to handle multiple mail identities dynamically. Here’s one simple trick with Postfix.

If you want the following:
* bob.microsoft@digitalpixies.local
* bob.ebay@digitalpixies.local
* bob.vegas@digitalpixies.local

forwarded to bob@digitalpixies.local, then edit /etc/postfix/main.cf and add/edit the following line

virtual_maps = regexp:/etc/postfix/virtual.regexp

then in the file /etc/postfix/virtual.regexp, put in:

/^(.*)\.(.*)\@digitalpixies\.local$/       ${1}@digitalpixies.local

For more better control over mail routing and spam filtering, I recommend using Haraka instead.