archiving rules

Nerijus Baliunas nerijusb at dtiltas.lt
Tue Dec 23 14:23:22 GMT 2014


On Tue, 23 Dec 2014 15:11:32 +0200 Nerijus Baliunas <nerijusb at dtiltas.lt> wrote:

> Messages are archived correctly. The problem is, when the message is sent like this:
> To: user1 at externaldomain.lt
> Cc: user2 at domain.lt
> 
> The message is sent to both user1 at backup.domain.lt and user2 at backup.domain.lt.
> Is it possible TOUSER in above rule to be used only if recipient domain is local, i.e. domain.lt?

I use postfix and have in main.cf:
virtual_mailbox_domains = proxy:mysql:/etc/postfix/sql/mysql_virtual_domains_maps.cf, backup.domain.lt
virtual_transport = dovecot
dovecot_destination_recipient_limit = 1
backup_destination_recipient_limit = 1

transport:
backup.domain.lt           backup:

master.cf:
dovecot   unix  -       n       n       -       -       pipe
  flags=DRhu user=vmail:vmail argv=/usr/libexec/dovecot/dovecot-lda -f ${sender} -d ${user}@${nexthop}

backup   unix  -       n       n       -       -       pipe
  flags=DRhu user=vmail:vmail argv=/usr/libexec/dovecot/dovecot-lda -f ${sender} -d backup at domain.lt -m ${user}

So all the backup email goes to backup at domain.lt mailbox and subdirs (named as
expanded _TOUSER_) are created because of -m ${user}. The problem is, that
subdirs are created even for external users, if a message is sent To: user1 at externaldomain.lt
and Cc: user2 at domain.lt.

Regards,
Nerijus


More information about the MailScanner mailing list