Question

SMTP error (gmail)

I try to send an email via smtp but I get an error from nginx Server Error (500).

if I run the site on a local machine, then the letters go away, but the server fails.

result from command netstat -ntlp | grep LISTEN

tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 20380/nginx: master tcp 0 0 127.0.0.53:53 0.0.0.0:* LISTEN 2702/systemd-resolv tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 957/sshd tcp6 0 0 :::22 :::* LISTEN 957/sshd

I set up the server manual which indicated the following settings https://gist.github.com/postrational/5747293#file-hello-nginxconf

I also tried to open the port through the command, but this did not help. iptables -A OUTPUT -p tcp -d <myIPdroplet> --dport 587 -j ACCEPT

can someone help me with the problem?

Subscribe
Share

in log file gunicorn_supervisor.log didn`t have any errors. any ideas ?


Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hi @MrWhilter,

Have you actually installed a service to send out mails? If you haven’t, I’ll suggest checking out Postfix, it will be exactly what you need. DigitalOcean have a pretty good article on how to install and configure it to work. I’m providing you with the Ubuntu article however, if you are using Apache there is one for it as well -

https://www.digitalocean.com/community/tutorials/how-to-install-and-configure-postfix-on-ubuntu-18-04

Regards, KDSys