Thanks, Michael - here’s what actually happened on today’s install and how I worked out that port 587 was the root cause.
When I first ran ./discourse-doctor at 50:30, it clearly showed that outbound SMTP on 587 was failing. There were no successful test emails anywhere in that part of the process. Because of that, at 51:38 I changed the SMTP port to 2525 and rebuilt the container. As soon as the app came back up, the first mail test at 57:46 succeeded immediately.
At 57:58 I noted that my Mailgun account still hadn’t activated - so the doctor was correct in saying SMTP failure was not due to credentials, but to the port being blocked by DigitalOcean.
Since Brevo is quicker to get running, I switched providers: starting the setup at 58:40, selected the Free plan at 1:01:12, swapped the DNS records at 1:02:29, and updated the SMTP settings in app.yml at 1:04:37. At 1:06:08 I pointed out that the GUI displays DISCOURSE_SMTP_DOMAIN even when the variable isn’t populated by ./discourse-setup, which is why the blank field initially made me think something was misconfigured.
After finishing the Brevo configuration, I reran ./discourse-doctor at 1:42:10, and at 1:42:25 it confirmed a successful outbound email - again using port 2525.
To answer your specific questions:
- How did I discover DigitalOcean was blocking 587?
./discourse-doctor reported 587 failing immediately, and switching to 2525 fixed it instantly. The video shows this sequence clearly. - Did I use rake emails:test?
Not at the time - I was relying on ./discourse-doctor and the admin UI test email. I didn’t realise emails:test existed until you mentioned it. I’ll absolutely use it going forward since it gives clearer in-container diagnostics. - Was the missing DISCOURSE_SMTP_DOMAIN related?
No - the blank GUI field was a red herring. The actual issue was DigitalOcean blocking port 587; once I moved to 2525, both Mailgun (once activated) and Brevo worked fine.
Thanks again - your explanation of what DISCOURSE_SMTP_DOMAIN actually affects (EHLO only) helped clear up why the missing value didn’t matter.