So it took me about 3 hours from spinning up a new VPS, locking down ssh and installing a firewall, and completing the self-hosting directions. I have photos uploading to my cloud, but email is not working yet. I have about 6 months experience with docker, so still fairly new at it but knowing how to install docker-ce and docker-compose already saved a bunch of time since I knew right away what some of the errors were when running the bootstrap script before those were installed.
There were some missing instructions when starting with a brand new Ubuntu install. To start out I already had ufw installed and was only allowing my ssh port. I found out from failures in the bootstrap script that these commands should be run to install prerequisites:
More notes.
Creating a new mailbox in postfix.admin results in an error.
Go into the docker:
sudo docker exec -it eelomailserver bash
cat /etc/postfix/main.cf | grep virtual_mailbox_base
virtual_mailbox_base = /var/mail
root@mail:/# ls -l /var/mail
total 40
drwxr-xr-x 3 clamav clamav 4096 Oct 24 21:00 clamav
drwxr-xr-x 3 vmail vmail 4096 Oct 23 02:30 dkim
drwxr-xr-x 2 root root 4096 Oct 23 02:32 dovecot
drwxr-xr-x 3 root root 4096 Oct 23 02:30 postfix
drwxr-x— 2 _rspamd _rspamd 12288 Oct 23 02:49 rspamd
drwxr-xr-x 2 vmail vmail 4096 Oct 23 02:30 sieve
drwxr-xr-x 2 root root 4096 Oct 23 02:30 ssl
drwxr-xr-x 3 vmail vmail 4096 Oct 23 02:30 vhosts
That doesn’t look right, where are the mailboxes?
errors in /var/log/mail.warn
2019-10-23T02:49:19.681846+00:00 mail dovecot: master: Fatal: Dovecot is already running with PID 58 (read from /var/run/dovecot/master.pid)
root@mail:/# service postfix status
[ ok ] postfix is not running.
root@mail:/# service dovecot status
doveconf: Warning: service auth { client_limit=1000 } is lower than required under max. load (1400)
doveconf: Warning: service anvil { client_limit=1000 } is lower than required under max. load (1203)
[ ok ] dovecot is running.
root@mail:/# service postfix restart
[ ok ] Stopping Postfix Mail Transport Agent: postfix.
[…] Starting Postfix Mail Transport Agent: postfixpostfix/postfix-script: fatal: the Postfix mail system is already running
failed!
root@mail:/# service dovecot restart
[ ok ] Restarting IMAP/POP3 mail server: dovecot.
root@mail:/# rm /var/spool/postfix/pid/master.pid
root@mail:/# service postfix restart
[ ok ] Stopping Postfix Mail Transport Agent: postfix.
[ ok ] Starting Postfix Mail Transport Agent: postfix.
root@mail:/# tail -10 /var/log/mail.err
2019-10-25T02:19:32.064288+00:00 mail postfix/master[4912]: fatal: bind 0.0.0.0 port 25: Address already in use
2019-10-25T02:35:27.118920+00:00 mail postfix/master[5130]: fatal: bind 0.0.0.0 port 587: Address already in use
There could be something wrong with /etc/postfix/master.cf
I wish I knew more about this stuff. Packing it in for tonight.
Actually the bootstrapping should do all those prerequisites by itself and it is tested/confirmed to be working on 18.04.
It should theoretically also working on 16 but that is not tested so who knows
Mailboxes should be in /var/mail/vhosts/yourdomain/username
However they are also mounted to the outside /mnt/repo-base/volumes/somfolder (can’t remember). As you know as you have some docker experience changes inside the container are not persisting a recreation.
Have you considered starting from scratch with Ubuntu 18 instead of 16. That has two benefits. It is tested to be working and comes with for more years of support (speaking about lts)
Let’s not focus on container internals for trouble shooting. Let us assume that as they are containers they are reproducibly configured correctly.
It is some issue outside on the host. It starts with the prerequisite steps you had to take. They should be not necessary. It would be great if you could start over (blank, brand new system) and just follow docs (ideally with 18) and if it fails share the logs/messages here to find out what is going on. Thank you!
I thought this meant to enter an email I already own as something like a recovery email address. So I did that, using another email address from a domain other than the one I am using for my self hosted e cloud. Was that the right thing to do?
OK I looked back at a bunch of notes I took while doing the install and noticed this output:
Adding email accounts used by system senders (drive, …)
Config::read(): attempt to read undefined config option “database_socket”, returning null
Welcome to Postfixadmin-CLI v0.2
PHP Warning: A non-numeric value encountered in /postfixadmin/model/MailboxHandler.php on line 227
Warning: A non-numeric value encountered in /postfixadmin/model/MailboxHandler.php on line 227
fsockopen failed - errno: 110 - errstr: Operation timed out
Your understanding of the alternative email question is correct. Maybe we need to clarify this in the docs.
What provider is this? I can recommend Hetzner cloud, good price/value. Hetzner.de has various fresh os images. If you are skipping the office set up (currently anyways broken) a machine of type cx11 is sufficient. Under 3€/month. With 7 daily db snapshots 3,50€, So quite affordable
I tried Hetzner but they wanted me to send a scanned image of my drivers license. I wasn’t willing to do that. I use schnellno.de, I won’t use anything from Amazon or 5 eyes based.