I would like to use sendmail
in a docker container to send email. I was able to do this before for my own site when I used a certain script to set everything up.
When I try this now sendmail
tells me Deferred: Temporary AUTH failure
but the next line says Message accepted for delivery
. However, the message is not sent as I use Mailgun for SMTP credentials and their logs never report the email that sendmail
tries to send. I have confirmed my Mailgun credentials are still valid because I can use their REST API to send mail.
I noticed when I change the port from 587
to 465
or 25
in the sendmail.mc
, it is not able to connect to smtp.mailgun.org
at all. It is only when I use port 587
that I get as far as the Temporary AUTH failure
. How can I resolve this authorization failure? I'm 100% sure that the correct credentials are in my /etc/mail/authinfo/auth
file. I tried ending that file with "M:LOGIN"
, "M:PLAIN"
, and "M:PLAIN LOGIN"
, and "M:EXTERNAL"
but to no avail.
How on earth do I configure sendmail
to send mail with my Mailgun SMTP credentials over port 587 without this "Deferred: Temporary AUTH failure" error?