Postfix + Dovecot + Maildir + IMAPs
In my quest to move away from UW-Imap I needed a new IMAP/POP3 server to store my mail. Specifically I needed one that supports Maildir as my old mbox mailboxes with 5000+ messages in them were just too slow. Fedora Core 3 comes with both Postfix and Dovecot, SMTP and IMAP/POP3 servers respectively, so setting it up is really quite simple. One word of warning, Cyrus-IMAP also comes with Fedora Core 3 but I highly recommend staying away from it. It's much more complicated and only really neccessary if you have a lot of users you want to host mail for. In my case I'm hosting mail for less than 10 users so Dovecot is perfect!
First install Postfix, and Dovecot, and remove sendmail:
yum install postfix
yum install dovecot
yum remove sendmail
Next configure postfix (/etc/postfix/main.cf) to deliver mail to Maildir directories instead of the default mbox. I'm also assuming you already know how to configure Postfix to accept mail for the domain youo want it be authoritative for.
home_mailbox = Maildir/
Send a message to a local user and check the maillog to make sure it was delivered correctly. Messages to that user should be stored in:
/home/(user)/Maildir/new
Assuming mail is getting delivered to that user's mailbox simply start Dovecot and login with that username/password. Dovecot only listens on IMAPs by default, edit the /etc/dovecot.conf to enable any other protocols you want to run (IMAP, POP3, or POP3s).
Dovecot will use a generic SSL cert with localhost.localdomain as the server name. You can make your own cert using the following command:
openssl req -new -x509 -nodes -out /tmp/public.pem -keyout /tmp/private.pem -days 3650
cp /tmp/public.pem /usr/share/ssl/certs/dovecot.pem
cp /tmp/private.pem /usr/share/ssl/private/dovecot.pem
service dovecot restart
Done! Grand total of about 10 minutes of tweaking to get a fully workable SMTP/IMAP/Maildir solution.
Note: I even configured Postfix to have procmail process and deliver the mail which gives even more flexibility. Just remember to have your .procmailrc deliver to Maildir directories (directories ending in a /) as the default is mbox.