[Dovecot] (OT) Advice on best way to collect mail from multiple domains and deliver to users via Dovecot IMAP.

Dave Hatton lists at starground.it
Wed Jun 20 20:20:21 EEST 2007


Hi

Sorry if this is an inappropriate question to ask here. If it is maybe there
is a better place to ask this question?

I would like to collect email sent to multiple users (with previously
unknown usernames) sent to multiple domains and then deliver this email to a
specific set of users on my server based upon some predefined rules, with a
catchall for mails that aren't caught by these rules.


So as an example, I might have domains:- example.com, example.co.uk,
someotherdomain.com and I'd like to say to a sender "just send a mail to
anything at example.com". I'd like to be able to make up recipients on the fly
when subscribing to a service so that I can filter mails to this address out
at a later time.

The method I devised when I set this up using dovecot .99 is as follows.

I currently have the hosting service for the domains forwarding all email to
a singular mailbox at my ISP and I user fetchmail to pop3 the mail down from
this one mailbox. 
The mail is then passed to postfix where I use the luser_relay option to map
all unknown recipients to a local address so that it doesn't get bounced.

Postfix then delivers the mail via the mailbox_command to maildrop where a
series of rules inspect the envelope headers and write the mail using the
"to" option to an appropriate maildir for the target user.

Is this a good approach?
Would I be better off using dovecot LDA and sieve?

Any advice or ideas would be gratefully received.

Daveh




More information about the dovecot mailing list