Answered: Q2A running in Docker hosted on AWS. How can I send mail to users?

Post date: 2022-06-28 18:58:27
Views: 81

You don't need to expose ports on the container for sending mail. However, because the container is most likely on an isolated network on the host system you need something to relay mail through. The top answer to the Stack Overflow question @GateOverflow linked to uses an MTA (Mail Transfer Agent, vulgo mail server) on the host for that purpose.

Since your Q2A instance seems to be configured for using local mail (checkbox "Send email via SMTP instead of local mail" under Admin ? Emails left unchecked, which is the default setting) you also need some kind of null mailer inside the container. The top answer to the Stack Overflow question uses SSMTP for that purpose, but other software can be used as well, for example nullmailer or even a full MTA like Postfix with a null client configuration.

The mail flow then goes from Q2A to the null mailer and from there to the host MTA, which will (attempt to) deliver the mail to the recipient's mail server(s).

Note that the host MTA may need to be set up to relay through another MTA if your hosting provider is blocking outbound connections to port 25 (many providers do this for spam prevention).

For further troubleshooting please check e-mail-related logs of both container and host.

Please click Here to read the full story.
 
Other Top and Latest Questions:
China is still years behind the U.S. despite Huawei's breakthrough chips, Raimondo tells '60 Minutes'
AIG Travel Guard insurance review: What you need to know
Protein calories not adding up
How can i solve the problem?
Movie: A Certain Kind of Death
Fallout: The Beginning
Fallout: The Past
Tesla slides 4%, Li Auto sinks 8% as EV makers slash prices amid fierce competition
Ex-JetBlue CEO Robin Hayes to run Airbus North America
Crypto prices gain to start the week following first Bitcoin halving since 2020