[Dovecot] Override quota rules based on mail's content
Andreas Calvo Gómez
andreas.calvo at admi.esci.es
Thu Sep 10 14:13:31 EEST 2009
Hi,
I've a mail server with Postfix and Dovecot, using a LDAP backend to get
the users.
I've also configure quota rules, and I'm able to get the quota from
LDAP.
But I need the mails that come from the local domain to bypass the quota
rule and be delivered to the users' inbox.
Is there any way to do that?
Information required by Dovecot's mailing list rules:
+++ dovecot.conf +++
# 1.1.11: /etc/dovecot/dovecot.conf
# OS: Linux 2.6.28-15-server x86_64 Ubuntu 9.04 ext4
log_timestamp: %Y-%m-%d %H:%M:%S
protocols: imap
disable_plaintext_auth: no
login_dir: /var/run/dovecot/login
login_executable: /usr/lib/dovecot/imap-login
login_user: postfix
valid_chroot_dirs: /var/spool/dovecot
first_valid_uid: 1000
first_valid_gid: 512
mail_privileged_group: mail
mail_location: maildir:/var/spool/dovecot/%n/
mail_plugins: quota imap_quota
imap_client_workarounds: delay-newmail outlook-idle netscape-eoh
tb-extra-mailbox-sep
auth default:
mechanisms: plain login
default_realm: esci.es
username_format: %Lu
passdb:
driver: pam
passdb:
driver: ldap
args: /etc/dovecot/dovecot-ldap.conf
userdb:
driver: prefetch
userdb:
driver: passwd
userdb:
driver: ldap
args: /etc/dovecot/dovecot-ldap-userdb.conf
socket:
type: listen
client:
path: /var/spool/postfix/private/auth
mode: 432
user: postfix
group: postfix
master:
path: /var/run/dovecot/auth-master
mode: 384
user: mail
group: mail
plugin:
quota: maildir:User quota
quota_rule: *:storage=50M
quota_rule2: Trash:ignore
+++ dovecot-ldap.conf +++
hosts = ldap.esci.es
auth_bind = yes
ldap_version = 3
base = ou=Users, dc=esci, dc=es
scope = subtree
user_attrs =
homeDirectory=home,uidNumber=uid,gidNumber=gid,mailQuota=quota_rule=*:storage=%$M
user_filter = (&(objectClass=posixAccount)(|(mail=%u)(uid=%u)(uid=%n)))
pass_attrs = uid=user,userPassword=password,\
homeDirectory=userdb_home,uidNumber=userdb_uid,gidNumber=userdb_gid,mailQuota=userdb_quota_rule=*:storage=%$M
pass_filter = (&(objectClass=posixAccount)(|(mail=%u)(uid=%u)))
default_pass_scheme = SSHA
Thanks.
---------------------
Andreas Calvo Gómez <andreas.calvo at admi.esci.es>
Dept. Informàtica ESCI
Pg. Pujades, 1 08003 Barcelona
tel. (34) 932954710 ext.233 fax. (34) 932954720
http://www.esci.es
--------------------
More information about the dovecot
mailing list