Files
Mail-Server/dovecot/dovecot.conf
2026-03-13 07:43:43 +00:00

176 lines
3.0 KiB
Plaintext

###
### Version settings
#############################
dovecot_config_version = 2.4.0
dovecot_storage_version = 2.4.0
###
### Logging settings
#############################
log_path = /var/log/dovecot.log
auth_verbose=yes
###
### Protocol settings
#############################
protocols {
lmtp = yes
imap = yes
}
protocol imap {
mail_plugins {
imap_sieve = yes
}
mail_max_userip_connections = 5
imap_idle_notify_interval = 29 mins
}
protocol lmtp {
mail_plugins {
sieve = yes
notify = yes
push_notification = yes
}
postmaster_address = postmaster@tobiastime.xyz
}
###
### SSL settings
#############################
#actually use the proper paths
ssl_server_cert_file = /path/2/fullchain.pem
ssl_server_key_file = /path/2/privkey.pem
ssl_server_dh_file = /path/2/dh.pem
ssl_server_prefer_ciphers = server
ssl_cipher_list = ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384
###
### Dovecot services
################################
service lmtp {
#utilize proper path
unix_listener /path/2/private/dovecot-lmtp {
mode = 0660
group = postfix
user = postfix
}
}
service auth {
### Auth socket for Postfix
unix_listener /path/2/postfix/private/auth {
mode = 0660
user = postfix
group = postfix
}
### Auth socket for LMTP
unix_listener auth-userdb {
mode = 0660
user = vmail
group = vmail
}
}
service anvil {
unix_listener anvil-auth-penalty {
mode = 0660
user = vmail
group = vmail
}
}
###
### Client authentication
#############################
auth_mechanisms = plain login
auth_username_format = %{user | lower }
auth_failure_delay = 15s
userdb passwd {
}
passdb pam {
}
###
### Address tagging
########################
recipient_delimiter = +
lmtp_save_to_detail_mailbox = yes
###
### Mail location
#######################
mail_uid = vmail
mail_gid = vmail
mail_privileged_group = vmail
mail_path = ~/mail
mailbox_list_layout = fs
mail_driver = maildir
mail_home = /home/%{user | username | lower}/Mail
###
### Mailbox configuration
########################
namespace inbox {
inbox = yes
mailbox Spam {
auto = subscribe
special_use = \Junk
}
mailbox Trash {
auto = subscribe
special_use = \Trash
}
mailbox Drafts {
auto = subscribe
special_use = \Drafts
}
mailbox Sent {
auto = subscribe
special_use = \Sent
}
}
###
### Mail plugins
############################
sieve_plugins {
sieve_imapsieve = yes
sieve_extprograms = yes
}
sieve_script default {
type = before
# use actual path
path = /path/2/sieve/default.sieve
}
mailbox Spam {
sieve_script spam {
type = before
cause = copy
# use actual path
path = /path/2/learn-spam.sieve
}
}