[Dovecot] Automatically deleting Trash a la Courier

Jeff Kowalczyk jtk at yahoo.com
Sun Oct 8 19:20:56 UTC 2006


Timo Sirainen wrote:
>  # Expire plugin. Mails are expunged from mailboxes after being there the
>  # configurable time. The first expiration date for each mailbox is stored in
>  # a dictionary so it can be quickly determined which mailboxes contain
>  # expired mails. The actual expunging is done in a nightly cronjob, which
>  # you must set up:
>  #   dovecot --exec-mail ext /usr/libexec/dovecot/expire-tool
>  #expire = Trash 7 Spam 30
>  #expire_dict = db:/var/lib/dovecot/expire.db

For users implementing the expire-tool as an email retention policy, it
may be helpful to add path wildcarding and exclusion to handle users with
folder heirarchies.

e.g., To implement a 1-year retention policy on messages in all folders,
excluding all messages in and in subfolders of 'Archived Email':

  expire = Trash 7 Spam 30 * 365
  expire_exclude = Archived\ Email\\*





More information about the dovecot mailing list