Question

My web (Node.js) application has a form that people fill out and send the inquiry to web admin (myself @ gmail). I use nodemailer before when I wasn't on AWS. The old server has SMTP. The amount of emails sending out from the server to my gmail is small, very small.

Now, I've moved to AWS EC2. I would like to keep using nodemailer for sending out email in the code. For setting up mail server or enable me to send out mail, Should I:

1) Use sendmail? What's the drawback? Will it be blocked by gmail?

2) Set up my own SMTP server (postfix). But I don't need to do bulk email or receiving emails though...

3) Use AWS SES service.

Also, do I need to open up port 25 from my server in order to send out email?

Thanks.

Was it helpful?

Solution

I recommend using SES. Amazon sets up the DNS records and adds signatures to the messages, greatly reducing the chance they will be flagged as spam. And it's easier to do than setting up your own SMTP server. There's even an Amazon AWS SDK for node.js that supports SES.

If you use SES you do not need to open port 25. You don't need to open any incoming ports; you connect to SES via a normal https URL. (You don't need to open any incoming ports to use SMTP or sendmail to send mail out, either.)

OTHER TIPS

I personally would prefer running my own email/MTA server. It allows more flexibility and more control.

BUT it is up to you to decide if it cost effective in your case. Badly managed mail server is not a gain, it is a costly liability.

You do need to USE SMTP, in your PHP script that's if you have one, you should somehow include the SMPT like this

ini_set ("SMTP","mail.internetprovider.com"); ini_set ("sendmail_from","yourmail@mail.internetprovider.co.za");

Then port 25 has to be opened as well, do you know how to do that? if not, to open the port you can type inetmgr in you run area after typing start then r, these silly instructions are not to make a fool out of you but I am just nor=t sure about the level of your knowledge and I am trying to help.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top