diff options
author | Alex Auvolat <alex@adnab.me> | 2021-01-16 17:07:01 +0100 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2021-01-16 17:07:01 +0100 |
commit | c74dc92febd1841c8ea5ff31caab0f941d57527d (patch) | |
tree | d05a203d95cac988952799667ec43c327a5d9038 /app/build/dovecot/conf | |
parent | 0c4ee40e01c95d7bf73236cbead5cc261f67eb9d (diff) | |
download | infrastructure-c74dc92febd1841c8ea5ff31caab0f941d57527d.tar.gz infrastructure-c74dc92febd1841c8ea5ff31caab0f941d57527d.zip |
Proposal: reorganize app/ folder by modules
Diffstat (limited to 'app/build/dovecot/conf')
-rw-r--r-- | app/build/dovecot/conf/all_before.sieve | 5 | ||||
-rw-r--r-- | app/build/dovecot/conf/dovecot-ldap.sample.conf | 8 | ||||
-rw-r--r-- | app/build/dovecot/conf/dovecot.conf | 79 | ||||
-rw-r--r-- | app/build/dovecot/conf/report-ham.sieve | 17 | ||||
-rw-r--r-- | app/build/dovecot/conf/report-spam.sieve | 9 |
5 files changed, 0 insertions, 118 deletions
diff --git a/app/build/dovecot/conf/all_before.sieve b/app/build/dovecot/conf/all_before.sieve deleted file mode 100644 index 7d2e57e..0000000 --- a/app/build/dovecot/conf/all_before.sieve +++ /dev/null @@ -1,5 +0,0 @@ -require ["fileinto", "mailbox"]; -if header :contains "X-Spam-Flag" "YES" { - fileinto :create "Junk"; -} - diff --git a/app/build/dovecot/conf/dovecot-ldap.sample.conf b/app/build/dovecot/conf/dovecot-ldap.sample.conf deleted file mode 100644 index 472d5e8..0000000 --- a/app/build/dovecot/conf/dovecot-ldap.sample.conf +++ /dev/null @@ -1,8 +0,0 @@ -hosts = ldap.example.com -dn = cn=admin,dc=example,dc=com -dnpass = s3cr3t -base = dc=example,dc=com -scope = subtree -user_filter = (&(mail=%u)(&(objectClass=inetOrgPerson)(memberOf=cn=email,ou=groups,dc=example,dc=com))) -pass_filter = (&(mail=%u)(&(objectClass=inetOrgPerson)(memberOf=cn=email,ou=groups,dc=example,dc=com))) -user_attrs = mail=/var/mail/%{ldap:mail} diff --git a/app/build/dovecot/conf/dovecot.conf b/app/build/dovecot/conf/dovecot.conf deleted file mode 100644 index 0d5068c..0000000 --- a/app/build/dovecot/conf/dovecot.conf +++ /dev/null @@ -1,79 +0,0 @@ -auth_mechanisms = plain login -auth_username_format = %u -log_timestamp = "%Y-%m-%d %H:%M:%S " -mail_location = maildir:/var/mail/%u -mail_privileged_group = mail - -log_path = /dev/stderr -info_log_path = /dev/stdout -debug_log_path = /dev/stdout - -protocols = imap sieve lmtp - -ssl_cert = < /etc/ssl/certs/dovecot.crt -ssl_key = < /etc/ssl/private/dovecot.key - -service auth { - inet_listener { - port = 1337 - } -} - -passdb { - args = /etc/dovecot/dovecot-ldap.conf - driver = ldap -} - -service lmtp { - inet_listener lmtp { - address = 0.0.0.0 - port = 24 - } -} - -service imap-login { - inet_listener imap { - port = 143 - } - inet_listener imaps { - port = 993 - } -} - -userdb { - args = uid=mailstore gid=mailstore home=/var/mail/%u - driver = static -} - -protocol imap { - mail_plugins = $mail_plugins imap_sieve -} - -protocol lda { - auth_socket_path = /var/run/dovecot/auth-master - info_log_path = /var/log/dovecot-deliver.log - log_path = /var/log/dovecot-deliver-errors.log - postmaster_address = postmaster@deuxfleurs.fr - mail_plugins = $mail_plugins sieve -} - -plugin { - sieve = file:~/sieve;active=~/dovecot.sieve - sieve_before = /etc/dovecot/all_before.sieve - - # antispam learn - sieve_plugins = sieve_imapsieve sieve_extprograms - sieve_global_extensions = +vnd.dovecot.pipe +vnd.dovecot.environment +vnd.dovecot.debug - sieve_pipe_bin_dir = /usr/bin - - imapsieve_mailbox1_name = Junk - imapsieve_mailbox1_causes = COPY FLAG APPEND - imapsieve_mailbox1_before = file:/etc/dovecot/report-spam.sieve - - imapsieve_mailbox2_name = * - imapsieve_mailbox2_from = Spam - imapsieve_mailbox2_causes = COPY APPEND - imapsieve_mailbox2_before = file:/etc/dovecot/report-ham.sieve - -} - diff --git a/app/build/dovecot/conf/report-ham.sieve b/app/build/dovecot/conf/report-ham.sieve deleted file mode 100644 index c5a994a..0000000 --- a/app/build/dovecot/conf/report-ham.sieve +++ /dev/null @@ -1,17 +0,0 @@ -require ["vnd.dovecot.pipe", "copy", "imapsieve", "environment", "variables", "vnd.dovecot.debug"]; - -if environment :matches "imap.mailbox" "*" { - set "mailbox" "${1}"; -} - -if string "${mailbox}" "Trash" { - stop; -} - -if environment :matches "imap.user" "*" { - set "username" "${1}"; -} - -pipe :copy "sa-learn" [ "--ham", "-u", "debian-spamd" ]; -debug_log "ham reported by ${username}"; - diff --git a/app/build/dovecot/conf/report-spam.sieve b/app/build/dovecot/conf/report-spam.sieve deleted file mode 100644 index 1be7389..0000000 --- a/app/build/dovecot/conf/report-spam.sieve +++ /dev/null @@ -1,9 +0,0 @@ -require ["vnd.dovecot.pipe", "copy", "imapsieve", "environment", "variables", "vnd.dovecot.debug"]; - -if environment :matches "imap.user" "*" { - set "username" "${1}"; -} - -pipe :copy "sa-learn" [ "--spam", "-u", "debian-spamd"]; -debug_log "spam reported by ${username}"; - |