假设我有两个虚拟用户:[email protected]
和[email protected]
.
我希望邮箱bugs
配置如下...:
mailbox Sent {
special_use = \Sent
}
mailbox Drafts {
special_use = \Drafts
}
mailbox "Priority 1" {
auto = subscribe
}
mailbox "Priority 2" {
auto = subscribe
}
mailbox "Priority 3" {
auto = subscribe
}
mailbox Unreplied {
auto = subscribe
}
mailbox Resolved {
auto = subscribe
}
...但是邮箱admin
配置了一些不同的文件夹:
mailbox Sent {
special_use = \Sent
}
mailbox Drafts {
special_use = \Drafts
}
mailbox System {
auto = subscribe
}
mailbox DMARC {
auto = subscribe
}
mailbox Archives {
auto = create
special_use = \Archive
}
mailbox Trash {
special_use = \Trash
}
mailbox Spam {
auto = create
special_use = \Junk
}
我不希望将电子邮件的文件夹bugs
复制到admin
电子邮件中,反之亦然。
我尝试的是使用命名空间,然后通过我的 passwd 文件设置每个虚拟用户的收件箱命名空间名称,如下所示:
admin:<password>::::::userdb_mail=maildir:/home/mail/admin NAMESPACE=primary userdb_namespace/primary/inbox=yes userdb_namespace/primary/list=yes userdb_namespace/primary/prefix=primary/
bugs:<password>::::::userdb_mail=maildir:/home/mail/bugs NAMESPACE=bugs userdb_namespace/bugs/inbox=yes userdb_namespace/bugs/list=yes userdb_namespace/bugs/prefix=bugs/
但 Dovecot 的日志说:
namespace configuration error: Duplicate namespace prefix: "" in=0 out=408 deleted=0 expunged=0 trashed=0 hdr_count=0 hdr_bytes=0 body_count=0 body_bytes=0
我的完整15-mailboxes.conf
:
namespace bugs {
list = no
type = private
mailbox Sent {
special_use = \Sent
}
mailbox Drafts {
special_use = \Drafts
}
mailbox "Priority 1" {
auto = subscribe
}
mailbox "Priority 2" {
auto = subscribe
}
mailbox "Priority 3" {
auto = subscribe
}
mailbox Unreplied {
auto = subscribe
}
mailbox Resolved {
auto = subscribe
}
}
namespace primary {
list = no
type = private
mailbox Sent {
special_use = \Sent
}
mailbox Drafts {
special_use = \Drafts
}
mailbox System {
auto = subscribe
}
mailbox DMARC {
auto = subscribe
}
mailbox Archives {
auto = create
special_use = \Archive
}
mailbox Trash {
special_use = \Trash
}
mailbox Spam {
auto = create
special_use = \Junk
}
}