title:Hosting your Own Email Part 2 date: 2021-06-15 03:46 tags: email opensmtpd
I plan on offering paid email accounts on gnucode.me, or your own domain. So your next email could be "YourName@gnucode.me" or "wilycatperson@YourDomain.com". The following is an explanation of how it will all work together. It is intended for anyone else wanting to set up an email server for a few email accounts.
Opensmtpd is my MTA (mail transfer agent), so it sends and receives email via smtp. Also, opensmtpd uses rspamd (or bogofilter) to limit spam.
Dovecot will serve my emails. For now I will set up emails in the maildir format, because this is easy to do. Eventually, I will store email in the dbox format.
imap.gnucode.me
will be where dovecot serves emailssmtp.gnucode.me
will be where opensmtp sends and receives emailI will have a few email accounts at gnucode.me <users>@gnucode.me
.
postmaster AT gnucode.me will point to my main user AT gnucode.me.
My email will be hosted at: /home/<user>/Maildir
I will tell dovecot to serve emails from the above directory via a config variable:
(dovecot-service #:config
(dovecot-configuration (mail-location "maildir:~/%n/Maildir")))
By default both opensmtpd and dovecot use regular login username authentication. So my username and password that I login via email is the same password that I use to login via ssh. So my email config for gnucode.me should look like this for gnus:
(nnimap "gnucode.me"
(nnimap-stream ssl)
(nnimap-address "imap.gnucode.me")
(nnimap-user "joshua"))
I login via "joshua" and . I would prefer to login via joshua AT gnucode.me. That way I can distinguish joshua AT gnucode.me and joshua AT propernaming.org
The above explanation strategy delivers all emails to /home/joshua/Maildir, which essentially limits my total email accounts to one.
The above has no spam filtering or email filtering.