IRedMail/FAQ/Archive.Mails.with.Postfix.Bcc

From iRedMail
Jump to: navigation, search

Reference: http://marc.info/?l=postfix-users&m=130524534504015&w=2

Note: You will lose per-user and per-domain bcc support after enable this archive method.

/etc/postfix/main.cf:
    recipient_bcc_maps = pcre:/etc/postfix/recipient_pcre
    recipient_delimiter = +

/etc/postfix/recipient_pcre:
    # Send copy of mail for each user@example.org recipient
    # to archive+user=example.org@example.com
    /^(.*)@([^@]+)$/	archive+$1=$2@example.com

This sends a copy for each recipient to archive@example.com, with
the original recipient encoded in the address extension.
Personal tools