LAN SMTP relay configuration issue


(Aleksey Napolskih) #1

Hello,

I have installed the latest release on the latest release of Ubuntu (18.04)

As with many other people I have a problem configuring SMTP.
We have a SMTP relay that runs in our network and Office 365 account that can be used, but I spent the last few days trying with no luck.

It appears that O365 does not support an authentication method supplied in Discourse, so I gave up on that.

When trying to configure the LAN relay, I found that the container (or perhaps the docker in general) does not inherit the host DNS. I was getting errors that my local SMTP server was not found

tcpdump -i docker0 -n port 53

does show that 8.8.8.8 is being used, and all LAN addresses are invisible.

further efforts led me to create a /etc/docker/daemon.json with the following
{ "dns": ["192.168.1.33", "8.8.8.8"], }

but once that file is created, the docker service does not start

I get exactly what is described in this topic - debian - docker service does not start after creating daemon.json - Stack Overflow

If anyone could assist me in resolving this issue, it would be much appreciated. We’d really like to use Discourse, but without SMTP, it’s pretty useless to us.


(Aleksey Napolskih) #2

so far, we’ve given up and reconfigured to O365 and it suddenly worked… we’re at the point of making a few tweaks and not being sure what made it work… nevertheless - Office 365 config works with the following:

DISCOURSE_SMTP_ADDRESS: 'smtp.office365.com'
DISCOURSE_SMTP_PORT: 587
DISCOURSE_SMTP_USER_NAME: 'your.email@domain.com'
DISCOURSE_SMTP_PASSWORD: 'password'
DISCOURSE_SMTP_AUTHENTICATION: login
DISCOURSE_SMTP_ENABLE_START_TLS: true