1

I have a postfix/dovecot mailserver setup, running fine. My problem is that different e-mail clients save sent e-mails in different folders. I realize that saving sent e-mail is not in the SMTP protocol, so my question doesn't regard that. I have installed Sieve succesfully in Dovecot but that only works on incoming mail (if I'm not mistaken).

Now my idea was to create a cronjob that moves all mails from different Sent folders to a 'default' one. So I want to select one 'default' Sent folder and move (not copy) all e-mails from alternative Sent folders to the default one on a regular basis, so that my users don't get confused over where to search for their sent e-mails on different clients. Can such a thing be done and if so, how would you approach it?

I'm not looking for a ready-cooked answer here, just some tips on how and where to start searching for information.

2

1 Answer 1

1

Following Michael Hamptons suggestion and some more details here I altered /etc/dovecot/15-mailboxes.conf like this (Dutch mailbox names included)

mail_plugins = $mail_plugins mailbox_alias

plugin {
  mailbox_alias_old = Sent
  mailbox_alias_new = Sent Messages
  mailbox_alias_old2 = Sent
  mailbox_alias_new2 = Verzonden items
  mailbox_alias_old3 = Sent
  mailbox_alias_new3 = Sent Items
}

# NOTE: Assumes "namespace inbox" has been defined in 10-mail.conf.
namespace inbox {
  # These mailboxes are widely used and could perhaps be created automatically:
  mailbox INBOX.Drafts {
    auto = subscribe
    special_use = \Drafts
  }
  mailbox INBOX.Junk {
    auto =  subscribe
    special_use = \Junk
  }
  mailbox INBOX.Trash {
    auto = subscribe
    special_use = \Trash
  }

  # For \Sent mailboxes there are two widely used names. We'll mark both of
  # them as \Sent. User typically deletes one of them if duplicates are created.
  mailbox Sent {
    special_use = \Sent
  }
  mailbox "Sent Messages" {
    special_use = \Sent
  }
  mailbox "Verzonden items" {
    auto = create
    special_use = \Sent
  }
  mailbox "Sent Items" {
    auto = create
    special_use = \Sent
  }

}

Of course this is not exhaustive, you can add more language specific (damn you outlook) mailbox aliases. Did a dovecot reload and status, no errors.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .