Modifications : etc/sv/postfix/local.sh
[lhc/ateliers.git] / etc / dovecot / dovecot.conf.m4
1 auth_mechanisms = plain
2 auth_ssl_require_client_cert = no
3 # NOTE: ne marche pas avec l'auth SASL depuis postfix qui ne fournit pas de certificat utilisateurice
4 auth_ssl_username_from_cert = yes
5 auth_verbose = yes
6 auth_debug = yes
7 disable_plaintext_auth = yes
8 first_valid_uid = 1000
9 lda_mailbox_autocreate = no
10 lda_mailbox_autosubscribe = yes
11 listen = *
12 log_timestamp = "%Y-%m-%d %H:%M:%S "
13 local_name imap.LOCAL_DOMAINNAME {
14 ssl_ca = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/crt+crl.self-signed.pem
15 ssl_cert = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/crt+crl.self-signed.pem
16 ssl_key = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/key.pem
17 }
18 local_name imap.cyclocoop.org {
19 ssl_ca = </etc/dovecot/cyclocoop.org/imap/x509/crt+crl.self-signed.pem
20 ssl_cert = </etc/dovecot/cyclocoop.org/imap/x509/crt+crl.self-signed.pem
21 ssl_key = </etc/dovecot/cyclocoop.org/imap/x509/key.pem
22 }
23 local_name pop.LOCAL_DOMAINNAME {
24 ssl_ca = </etc/dovecot/LOCAL_DOMAINNAME/pop/x509/crt+crl.self-signed.pem
25 ssl_cert = </etc/dovecot/LOCAL_DOMAINNAME/pop/x509/crt+crl.self-signed.pem
26 ssl_key = </etc/dovecot/LOCAL_DOMAINNAME/pop/x509/key.pem
27 }
28 local_name pop.cyclocoop.org {
29 ssl_ca = </etc/dovecot/cyclocoop.org/pop/x509/crt+crl.self-signed.pem
30 ssl_cert = </etc/dovecot/cyclocoop.org/pop/x509/crt+crl.self-signed.pem
31 ssl_key = </etc/dovecot/cyclocoop.org/pop/x509/key.pem
32 }
33 mail_debug = yes
34 mail_home = /home/mail/data/%d/%n
35 mail_location = maildir:/home/mail/data/%d/%n/Maildir:INDEX=/var/lib/dovecot-index/%d/%n:CONTROL=/var/lib/dovecot-control/%d/%n
36 # NOTE: INDEX et CONTROL sont sur une partition sans quota comme le demande la doc
37 # VOIR: http://wiki2.dovecot.org/Quota/FS
38 namespace {
39 #list = children
40 list = yes
41 location = maildir:/home/mail/data/%%d/%%n/Maildir:INDEX=/var/lib/dovecot-index/%d/%n/Shared/%%n:CONTROL=/var/lib/dovecot-control/%d/%n/Shared/%%n
42 prefix = Partages+%%n+
43 separator = +
44 subscriptions = yes
45 type = shared
46 }
47 mail_plugins = $mail_plugins acl quota virtual
48 #mail_privileged_group = mail
49 #mail_access_groups = mail
50 passdb {
51 args = scheme=plain username_format=%n /etc/dovecot/%d/passwd
52 driver = passwd-file
53 }
54 plugin {
55 acl = vfile:/etc/dovecot/acl/global.d
56 acl_anyone = allow
57 acl_shared_dict = file:/home/mail/acl/%d/shared.db
58 #antispam_allow_append_to_spam = yes
59 # NOTE: pour offlineimap
60 antispam_backend = pipe
61 #antispam_crm_args = -u;/home/mail/data/%d/.crm114;/usr/share/crm114/mailfilter.crm
62 antispam_crm_args = -u;/home/mail/crm114;/usr/share/crm114/mailfilter.crm
63 antispam_crm_binary = /usr/bin/crm
64 antispam_debug_target = syslog
65 #antispam_crm_env = HOME=%h;USER=%u
66 antispam_ham_keywords = NonJunk
67 antispam_pipe_program = /usr/bin/crm
68 antispam_pipe_program_args = -u;/home/mail/crm114;/usr/share/crm114/mailfilter.crm;--stats_only;--force
69 antispam_pipe_program_notspam_arg = --learnnonspam
70 antispam_pipe_program_spam_arg = --learnspam
71 antispam_pipe_program_unlearn_spam_args = --unlearn;--learnspam
72 antispam_pipe_program_unlearn_notspam_args = --unlearn;--learnnonspam
73 antispam_pipe_tmpdir = /home/mail/crm114/tmp
74 antispam_signature = X-CRM114-CacheID
75 antispam_signature_missing = move
76 antispam_spam = Junk
77 antispam_spam_keywords = Junk
78 antispam_trash = Trash
79 antispam_unsure = Unsure
80 antispam_verbose_debug = 0
81 quota = maildir:User quota
82 quota_rule = *:storage=256M
83 quota_rule2 = Trash:storage=+64M
84 recipient_delimiter = +
85 sieve = /home/mail/data/%d/%n/sieve
86 sieve_after = /etc/dovecot/sieve/after.d/
87 sieve_before = /etc/dovecot/sieve/before.d/
88 sieve_dir = /home/mail/data/%d/%n/sieve.d/
89 #sieve_extensions = +spamtest +spamtestplus
90 sieve_global_dir = /etc/dovecot/sieve/global.d/
91 sieve_max_script_size = 1M
92 sieve_quota_max_scripts = 0
93 sieve_quota_max_storage = 10M
94 sieve_spamtest_max_value = 10
95 sieve_spamtest_status_header = X-Spam-Score
96 sieve_spamtest_status_type = strlen
97 sieve_user_log = /home/mail/log/%d/sieve.%n.log
98 }
99 protocol imap {
100 mail_plugins = $mail_plugins antispam imap_acl imap_quota
101 namespace inbox {
102 inbox = yes
103 location =
104 list = yes
105 mailbox Drafts {
106 special_use = \Drafts
107 }
108 mailbox Junk {
109 special_use = \Junk
110 }
111 mailbox Sent {
112 special_use = \Sent
113 }
114 mailbox "Sent Messages" {
115 special_use = \Sent
116 }
117 mailbox Trash {
118 special_use = \Trash
119 }
120 prefix =
121 separator = +
122 }
123 }
124 protocol lda {
125 auth_socket_path = /var/run/dovecot/auth-userdb
126 hostname = LOCAL_DOMAINNAME
127 info_log_path =
128 log_path =
129 mail_plugins = $mail_plugins sieve
130 namespace inbox {
131 inbox = yes
132 location =
133 list = yes
134 prefix =
135 separator = +
136 }
137 postmaster_address = postmaster+dovecot+lda@LOCAL_DOMAINNAME
138 syslog_facility = mail
139 }
140 protocol lmtp {
141 #info_log_path = /tmp/dovecot-lmtp.log
142 mail_plugins = $mail_plugins sieve
143 namespace inbox {
144 inbox = yes
145 location =
146 list = yes
147 prefix =
148 separator = +
149 }
150 postmaster_address = postmaster+dovecot+lmtp@LOCAL_DOMAINNAME
151 }
152 protocol pop3 {
153 namespace all {
154 # NOTE: utilisé par /etc/dovecot/pop3/INBOX/dovecot-virtual
155 hidden = yes
156 list = no
157 location =
158 prefix = all+
159 separator = +
160 }
161 namespace inbox {
162 # NOTE: virtual namespace for the virtual INBOX. Use a global directory for dovecot-virtual files.
163 inbox = yes
164 hidden = yes
165 list = no
166 location = virtual:/etc/dovecot/pop3:INDEX=/var/lib/dovecot-index/%d/%n/POP3:LAYOUT=fs
167 prefix = pop3+
168 separator = +
169 }
170 pop3_client_workarounds =
171 pop3_fast_size_lookups = yes
172 pop3_lock_session = yes
173 pop3_no_flag_updates = yes
174 pop3_uidl_format = %g
175 # NOTE: use GUIDs to avoid accidental POP3 UIDL changes instead of IMAP UIDs.
176 }
177 protocol sieve {
178 mail_debug = yes
179 #mail_max_userip_connections = 10
180 #managesieve_implementation_string = Dovecot Pigeonhole
181 managesieve_max_compile_errors = 5
182 #managesieve_max_line_length = 65536
183 #managesieve_notify_capability = mailto
184 #managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave
185 }
186 protocols = imap lmtp pop3 sieve
187 service lmtp {
188 #executable = lmtp -L
189 process_min_avail = 2
190 unix_listener /var/spool/postfix/private/dovecot-lmtp {
191 user = postfix
192 group = postfix
193 mode = 0600
194 }
195 #user = mail
196 }
197 service auth {
198 user = root
199 unix_listener auth-userdb {
200 user = dovecot
201 group = root
202 mode = 0666
203 }
204 unix_listener /var/spool/postfix/private/auth {
205 user = postfix
206 group = postfix
207 mode = 0660
208 }
209 }
210 service imap {
211 #vsz_limit =
212 # NOTE: most of the memory goes to mmap()ing files.
213 # You may need to increase this limit if you have huge mailboxes.
214 process_limit = 1024
215 }
216 service imap-login {
217 inet_listener imap {
218 address = 127.0.0.1
219 port = 143
220 ssl = no
221 }
222 inet_listener imaps {
223 port = 993
224 ssl = yes
225 }
226 }
227 service pop3 {
228 process_limit = 1024
229 }
230 service pop3-login {
231 inet_listener pop3s {
232 port = 995
233 ssl = yes
234 }
235 }
236 ssl = required
237 ssl_ca = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/crt+crl.self-signed.pem
238 ssl_cert = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/crt+crl.self-signed.pem
239 ssl_cipher_list = ALL:!LOW:!SSLv2:!EXP:!aNULL
240 ssl_key = </etc/dovecot/LOCAL_DOMAINNAME/imap/x509/key.pem
241 ssl_verify_client_cert = yes
242 userdb {
243 driver = prefetch
244 }
245 userdb {
246 # NOTE: this userdb is only used by lda.
247 args = username_format=%n /etc/dovecot/%d/passwd
248 driver = passwd-file
249 }
250 verbose_ssl = no
251
252 # vim: ft=sh