Added configuration for gentoo / dovecot2
Signed-off-by: Florian Aders (EleRas) <eleras@froxlor.org>
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
driver = mysql
|
||||
connect = host=<SQL_HOST> dbname=<SQL_DB> user=<SQL_UNPRIVILEGED_USER> password=<SQL_UNPRIVILEGED_PASSWORD>
|
||||
default_pass_scheme = CRYPT
|
||||
password_query = "SELECT username AS user, password_enc AS password, CONCAT(homedir, maildir) AS userdb_home, uid AS userdb_uid, gid AS userdb_gid, CONCAT('*:storage=', quota,'M') AS userdb_quota_rule FROM mail_users WHERE (username = '%u' OR email = '%u') AND ((imap = 1 AND '%Ls' = 'imap') OR (pop3 = 1 AND '%Ls' = 'pop3') OR '%Ls' = 'smtp')"
|
||||
user_query = "SELECT CONCAT(homedir, maildir) AS home, uid, gid, CONCAT('*:storage=', quota,'M') AS quota_rule FROM mail_users WHERE (username = '%u' OR email = '%u')"
|
||||
@@ -0,0 +1,63 @@
|
||||
auth_mechanisms = plain login
|
||||
## allow Plaintext Logins from foreign IP if the Connection doesn't use TLS
|
||||
disable_plaintext_auth = no
|
||||
listen = *
|
||||
mail_access_groups = vmail
|
||||
mail_debug = no
|
||||
|
||||
protocols = imap pop3
|
||||
|
||||
### SSL Settings
|
||||
### After setting this options, set disable_plaintext_auth to yes (see above)
|
||||
#ssl_cert = </etc/ssl/server/<SERVERNAME>.pem
|
||||
#ssl_key = </etc/ssl/server/<SERVERNAME>.key
|
||||
|
||||
passdb {
|
||||
args = /etc/dovecot/dovecot-sql.conf
|
||||
driver = sql
|
||||
}
|
||||
|
||||
plugin {
|
||||
quota = maildir:User Quota
|
||||
}
|
||||
|
||||
service auth {
|
||||
unix_listener /var/spool/postfix/private/auth {
|
||||
group = postfix
|
||||
mode = 0660
|
||||
user = postfix
|
||||
}
|
||||
unix_listener auth-master {
|
||||
group = vmail
|
||||
mode = 0660
|
||||
user = vmail
|
||||
}
|
||||
}
|
||||
|
||||
userdb {
|
||||
driver = prefetch
|
||||
}
|
||||
|
||||
userdb {
|
||||
args = /etc/dovecot/dovecot-sql.conf
|
||||
driver = sql
|
||||
}
|
||||
|
||||
protocol imap {
|
||||
mail_plugins = quota imap_quota
|
||||
}
|
||||
|
||||
protocol pop3 {
|
||||
mail_plugins = quota
|
||||
pop3_uidl_format = UID%u-%v
|
||||
}
|
||||
|
||||
lda_mailbox_autocreate = yes
|
||||
protocol lda {
|
||||
auth_socket_path = /var/run/dovecot/auth-master
|
||||
mail_plugins = quota
|
||||
# postmaster is the one in charge of the mail system. MUST be set to a valid address!
|
||||
postmaster_address = admin@<SERVERNAME>
|
||||
sendmail_path = /usr/sbin/sendmail
|
||||
lda_mailbox_autocreate = 1
|
||||
}
|
||||
Reference in New Issue
Block a user