Simple Mail Server
I am trying to simply get mail from a remote pop3 account and redistribute it in my office to several computers. I am using getmail to get the mail from the remote server and store it in a maildir here called /mail/user1. I am using a separate getmailrc file to get mail from a separate remote account and store it in /mail/user2. Now I want to login to dovecot from computers on the network here and get the mail based on the user name. For example, if user2 logs in to dovecot, he should get the mail from /mail/user2.
I tried putting mail_location = /mail/%u in /etc/dovecot.conf (and also tried /mail/%n) but the mail clients seem to think there is no new mail even after i have sent several test messages. I have looked in /mail/user1/new and /mail/user2/new and the mail is indeed being delivered properly.
I am not set on using dovecot if you have an easier solution, but it seems like it should be pretty easy to do with dovecot and i am just doing something wrong.
Any input would be great!
Is this not possible?
Hi - The literature seems to say that you can use the user's home folder to put their mail: In each getmailrc declare:
type = Maildir
path = ~/.maildir/
and in dovecot.conf declare:
mail_location = maildir:~/.maildir
Of course you need to enable IMAP in dovecot.
No need to re-invent the wheel, look at HOWTO Fetch mails from multiple POP/IMAP-mailboxes and export them via IMAP to Thunderbird/SquirrelMail etc - Gentoo Linux Wiki
and modify for your distro.
So I have to use IMAP?? Why cant I use pop3?
You can use pop in dovecot.
"protocols = pop3"