tomclegg.net


Diary
Examples
    256-router
    adzap
    apache-double-reverse
    cacti-adodb-php4
    debian-quota
    diskonmodule
    dollarsperbyte
    dynip
    ezmlm-linux
    fbsdhabits
    freebsdclone
    macbook-quantal-sound
  >maildirpop3d-awfulhak<
    mandy
    md
    mrtg
    net-snmp
    nodefaultroute
    oracle9i
    oracle9i-bsd5
    oracle9i-client
    oracle9i-nat
    php-cgi
    php-commandline
    php-image
    php-kics
    php-mini_httpd
    pinouts
    pizzaperdollar
    plesk-symlink-php
    pxe
    qmail-linux
    qmail-qfilter
    racoon-sonicwall
    redundant-vpn
    rewriterule
    seahorse-workaround
    setting-locale-failed
    smalldog
    snmpv3-cacti
    spamassassin
    squid-tproxy
    supfile
    suse73
    svc-nmbd
    svc-smbd
    svc-smtpd
    switch-virtualbox-virsh
    toyotastereo
    vm
    vn-file
    wmp-invalid
    xcode-remote-install
    xen-eth0-renamed
    xen-monowall
    xen3-ubuntu-dapper
    zz-update-grub-fail
Hire Tom
Mostly Mozart
Patches
School
Scrapbook
Software
Telephones




colocation
comments
davidireland
edsgranola
faq
funsites
goodlooking
goodmovies
google-earth-saucy-amd64
houserules
liberating
resume
resume2
scratch
shopping
snacks
todo
university
warisbogus

maildirpop3d + dovecot + regular users
Posted January 23, 2006

You can make dovecot and maildircheckpw-dovecot offer user-controlled mailboxes and regular mailboxes at the same time.

This is a horrible solution. It is not recommended.

In /usr/local/etc/dovecot.conf, change default_mail_env to this.

default_mail_env = maildir:%h/Maildir

Restart dovecot.

/usr/local/etc/rc.d/dovecot.sh restart

Make sure checkpassword is in /usr/bin or /bin.

which checkpassword && ln -s `which checkpassword` /bin

Periodically, make sure there is a symlink from Maildir in each user-controlled mailbox.

For example, create /usr/local/sbin/hack-maildirs like this:

for d in /home/*
do
  for md in "$d"/Maildir-*
  do
    if [ -e "$md" ]
    then
      [ -e "$md/Maildir" ] || ln -s . "$md/Maildir"
    fi
  done
done

...and add this to /etc/crontab:

0 * * * * root sh /usr/local/sbin/hack-maildirs