| @@ -46,15 +46,17 @@ service pop3-login { | |||||
| } | } | ||||
| service lmtp { | service lmtp { | ||||
| unix_listener lmtp { | |||||
| #mode = 0666 | |||||
| unix_listener /var/spool/postfix/private/dovecot-lmtp { | |||||
| group = postfix | |||||
| mode = 0600 | |||||
| user = postfix | |||||
| } | } | ||||
| # Create inet listener only if you can't use the above UNIX socket | # Create inet listener only if you can't use the above UNIX socket | ||||
| #inet_listener lmtp { | #inet_listener lmtp { | ||||
| # Avoid making LMTP visible for the entire internet | # Avoid making LMTP visible for the entire internet | ||||
| #address = | #address = | ||||
| #port = | |||||
| #port = | |||||
| #} | #} | ||||
| } | } | ||||
| @@ -88,8 +90,8 @@ service auth { | |||||
| # permissions (e.g. 0777 allows everyone full permissions). | # permissions (e.g. 0777 allows everyone full permissions). | ||||
| unix_listener auth-userdb { | unix_listener auth-userdb { | ||||
| #mode = 0666 | #mode = 0666 | ||||
| #user = | |||||
| #group = | |||||
| #user = | |||||
| #group = | |||||
| } | } | ||||
| # Postfix smtp-auth | # Postfix smtp-auth | ||||
| @@ -115,7 +117,7 @@ service dict { | |||||
| # For example: mode=0660, group=vmail and global mail_access_groups=vmail | # For example: mode=0660, group=vmail and global mail_access_groups=vmail | ||||
| unix_listener dict { | unix_listener dict { | ||||
| #mode = 0600 | #mode = 0600 | ||||
| #user = | |||||
| #group = | |||||
| #user = | |||||
| #group = | |||||
| } | } | ||||
| } | } | ||||
| @@ -0,0 +1,20 @@ | |||||
| ## | |||||
| ## LMTP specific settings | |||||
| ## | |||||
| # Support proxying to other LMTP/SMTP servers by performing passdb lookups. | |||||
| #lmtp_proxy = no | |||||
| # When recipient address includes the detail (e.g. user+detail), try to save | |||||
| # the mail to the detail mailbox. See also recipient_delimiter and | |||||
| # lda_mailbox_autocreate settings. | |||||
| #lmtp_save_to_detail_mailbox = no | |||||
| # Verify quota before replying to RCPT TO. This adds a small overhead. | |||||
| #lmtp_rcpt_check_quota = no | |||||
| protocol lmtp { | |||||
| # Space separated list of plugins to load (default is global mail_plugins). | |||||
| #mail_plugins = $mail_plugins | |||||
| mail_plugins = $mail_plugins sieve | |||||
| } | |||||
| @@ -26,8 +26,8 @@ | |||||
| - name: Copying SSL configuration (10-ssl.conf) | - name: Copying SSL configuration (10-ssl.conf) | ||||
| copy: src=10-ssl.conf dest=/etc/dovecot/conf.d/10-ssl.conf | copy: src=10-ssl.conf dest=/etc/dovecot/conf.d/10-ssl.conf | ||||
| notify: restart dovecot | notify: restart dovecot | ||||
| - name: Copying LDA configuration (10-lda.conf - enable sieve plugin) | |||||
| template: src=15-lda.conf.j2 dest=/etc/dovecot/conf.d/15-lda.conf | |||||
| - name: Copying LMTP configuration (20-lmtp.conf - enable sieve plugin) | |||||
| copy: src=20-lmtp.conf dest=/etc/dovecot/conf.d/20-lmtp.conf | |||||
| notify: restart dovecot | notify: restart dovecot | ||||
| - name: Copying mailboxes configuration (15-mailboxes.conf - autocreate folders) | - name: Copying mailboxes configuration (15-mailboxes.conf - autocreate folders) | ||||
| copy: src=15-mailboxes.conf dest=/etc/dovecot/conf.d/15-mailboxes.conf | copy: src=15-mailboxes.conf dest=/etc/dovecot/conf.d/15-mailboxes.conf | ||||
| @@ -1,48 +0,0 @@ | |||||
| ## | |||||
| ## LDA specific settings (also used by LMTP) | |||||
| ## | |||||
| # Address to use when sending rejection mails. | |||||
| # Default is postmaster@<your domain>. %d expands to recipient domain. | |||||
| postmaster_address = {{ispmail_postmaster_address}} | |||||
| # Hostname to use in various parts of sent mails (e.g. in Message-Id) and | |||||
| # in LMTP replies. Default is the system's real hostname@domain. | |||||
| #hostname = | |||||
| # If user is over quota, return with temporary failure instead of | |||||
| # bouncing the mail. | |||||
| #quota_full_tempfail = no | |||||
| # Binary to use for sending mails. | |||||
| #sendmail_path = /usr/sbin/sendmail | |||||
| # If non-empty, send mails via this SMTP host[:port] instead of sendmail. | |||||
| #submission_host = | |||||
| # Subject: header to use for rejection mails. You can use the same variables | |||||
| # as for rejection_reason below. | |||||
| #rejection_subject = Rejected: %s | |||||
| # Human readable error message for rejection mails. You can use variables: | |||||
| # %n = CRLF, %r = reason, %s = original subject, %t = recipient | |||||
| #rejection_reason = Your message to <%t> was automatically rejected:%n%r | |||||
| # Delimiter character between local-part and detail in email address. | |||||
| #recipient_delimiter = + | |||||
| # Header where the original recipient address (SMTP's RCPT TO: address) is taken | |||||
| # from if not available elsewhere. With dovecot-lda -a parameter overrides this. | |||||
| # A commonly used header for this is X-Original-To. | |||||
| #lda_original_recipient_header = | |||||
| # Should saving a mail to a nonexistent mailbox automatically create it? | |||||
| #lda_mailbox_autocreate = no | |||||
| # Should automatically created mailboxes be also automatically subscribed? | |||||
| #lda_mailbox_autosubscribe = no | |||||
| protocol lda { | |||||
| # Space separated list of plugins to load (default is global mail_plugins). | |||||
| mail_plugins = $mail_plugins sieve | |||||
| } | |||||
| @@ -9,6 +9,7 @@ | |||||
| - dovecot-mysql | - dovecot-mysql | ||||
| - dovecot-pop3d | - dovecot-pop3d | ||||
| - dovecot-imapd | - dovecot-imapd | ||||
| - dovecot-lmtpd | |||||
| - dovecot-managesieved | - dovecot-managesieved | ||||
| - phpmyadmin | - phpmyadmin | ||||
| - spamass-milter | - spamass-milter | ||||
| @@ -30,12 +30,8 @@ | |||||
| - virtual-mailbox-maps | - virtual-mailbox-maps | ||||
| - virtual-alias-maps | - virtual-alias-maps | ||||
| - name: Define dovecot service in master.cf | |||||
| command: postconf -vM dovecot/unix='dovecot unix - n n - - pipe flags=DRhu user=vmail:vmail argv=/usr/lib/dovecot/dovecot-lda -f ${sender} -d ${recipient}' | |||||
| notify: restart postfix | |||||
| - name: Set virtual_transport to dovecot | |||||
| command: postconf virtual_transport=dovecot | |||||
| - name: Make Postfix use LMTP to send emails to Dovecot | |||||
| command: postconf virtual_transport=lmtp:unix:private/dovecot-lmtp | |||||
| - name: Restricting delivery to Dovecot to one email at a time | - name: Restricting delivery to Dovecot to one email at a time | ||||
| command: postconf dovecot_destination_recipient_limit=1 | command: postconf dovecot_destination_recipient_limit=1 | ||||