Page MenuHomeDevCentral

Dovecot Provisioning
Open, Needs TriagePublic

Description

In this task we will install and configure dovecot

Event Timeline

Adapted from https://gist.github.com/barryo/8918488:

dovecot-sql.conf.ext SQL queries

PostgreSQL query for password:

password_query = SELECT username as user, password as password, \
        homedir AS userdb_home, maildir AS userdb_mail, \
        concat('*:bytes=', quota) as userdb_quota_rule, uid AS userdb_uid, gid AS userdb_gid \
    FROM mailbox \
    WHERE username = '%Lu' AND active = '1' \
          AND ( access_restriction = 'ALL' OR POSITION( '%Us' IN access_restriction ) > 0 )

The MySQL user query can be used as is:

user_query = SELECT homedir AS home, maildir AS mail, \
        concat('*:bytes=', quota) as quota_rule, uid, gid \
    FROM mailbox WHERE username = '%u'