aports/config/dovecot/dovecot.conf

103 lines
1.7 KiB
Plaintext

## Dovecot configuration file
listen = *, ::
base_dir = /run/dovecot/
instance_name = redxen-production
login_greeting = RedXen Mail ready. DO NOT MESS WITH US OR WE WILL CUT YOUR BALLS OFF!
protocols = imap lmtp
# TLS stuff
ssl = yes
ssl_cert = </etc/redxen/letsencrypt/chain.crt
ssl_key = </etc/redxen/letsencrypt/private.key
# Authentication
auth_mechanisms = plain login
auth_username_chars = abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ01234567890.-_@
auth_username_format = %n
disable_plaintext_auth = yes
# Valid users
first_valid_uid = 8
last_valid_uid = 8
first_valid_gid = 12
last_valid_gid = 12
lda_mailbox_autocreate = yes
imap_capability = +SPECIAL-USE
# PostgreSQL UserDB
userdb {
driver = sql
args = /etc/redxen/dovecot/pgsql.conf
}
passdb {
driver = sql
args = /etc/redxen/dovecot/pgsql.conf
}
# Services
service imap-login {
inet_listener imap {
#address = none
port = 143
}
inet_listener imaps {
#address = none
port = 993
ssl = yes
}
}
service lmtp {
unix_listener lmtp {
mode = 0660
user = dovecot
group = mail
}
}
service auth {
unix_listener auth {
mode = 0660
user = dovecot
group = mail
}
user = root
}
# Mailbox
mail_home=/var/mail/%u
mail_location = maildir:/var/mail/%u:INBOX=/var/mail/%u/Inbox:LAYOUT=fs
mailbox_list_index = yes
namespace inbox {
type = private
inbox = yes
mailbox Archive {
special_use = \Archive
auto = create
}
mailbox Drafts {
special_use = \Drafts
auto = create
}
mailbox Sent {
special_use = \Sent
auto = create
}
mailbox Junk {
special_use = \Junk
auto = create
autoexpunge = 30d
}
mailbox Trash {
special_use = \Trash
auto = create
autoexpunge = 7d
}
}