13 Oct
2006
13 Oct
'06
3 p.m.
I was thinking about renaming default_mail_env to something that is more understandable. I'll keep it working for backwards compatibility anyway. How about:
Location for users' mailboxes. This is the same as the old default_mail_env
setting. The default is empty, which means that Dovecot tries to find the
mailboxes automatically. This won't work if the user doesn't have any mail
yet, so you should explicitly tell Dovecot the full location.
If you're using mbox, giving a path to INBOX file (eg. /var/mail/%u) isn't
enough. You'll also need to tell Dovecot where the other mailboxes are and
where Dovecot can place its index files.
There are a few special variables you can use, eg.:
%u - username
%n - user part in user@domain, same as %u if there's no domain
%d - domain part in user@domain, empty if there's no domain
%h - home directory
See doc/variables.txt for full list. Some examples:
mail_location = maildir:/var/mail/%1u/%u/Maildir
mail_location = mbox:~/mail/:INBOX=/var/mail/%u
mail_location = mbox:/var/mail/%d/%n/:INDEX=/var/indexes/%d/%n
http://wiki.dovecot.org/MailLocation
#mail_location =