Postfix configuration

This page mentions all Postfix configuration parameters, which have to be modified and/or added in/to the Postfix

Add or replace the following configuration parameters in the global Postfix configuration file. The Postfix PostgreSQL client configuration files (pgsql-*.cf) mentioned below will be created when vmm will be installed.

sql      = pgsql:${config_directory}/
proxysql = proxy:${sql}

# relocated users from the database
#relocated_maps = ${proxysql}

# transport settings from our database
transport_maps = ${proxysql}

# virtual domains, mailboxes and aliases
virtual_mailbox_domains = ${proxysql}
virtual_alias_maps = ${proxysql}
virtual_minimum_uid = 70000
virtual_uid_maps = ${sql}
virtual_gid_maps = ${sql}
virtual_mailbox_base = /
virtual_mailbox_maps = ${proxysql}

# dovecot lmtp (requires Dovecot ≧ v2.0.0)
virtual_transport = lmtp:unix:private/dovecot-lmtp

# dovecot SASL
smtpd_sasl_type = dovecot
smtpd_sasl_path = private/dovecot-auth
smtpd_sasl_auth_enable = yes
# Keep smtpd_sasl_local_domain identical to Dovecot's auth_default_realm:
# empty. Both are empty by default. Let it commented out.
# Read more at:
#smtpd_sasl_local_domain =
smtpd_sasl_security_options = noplaintext, noanonymous
#broken_sasl_auth_clients = yes

smtpd_recipient_restrictions =

Using Dovecot’s LMTP

In order to use Dovecot’s LMTP as virtual_transport with Postfix make sure you have have:

  • lmtp in your protocols setting (dovecot.conf)

  • configured a lmtp listener: service lmtp {} (conf.d/10-master.conf)

  • set lmtp:unix:private/dovecot-lmtp as the domain.transport in your vmm.cfg.

If you want to switch the transport of existing domains and/or accounts, you can use the subcommands domaintransport and usertransport.