EC2 mail via gmail [closed]

我的梦境 提交于 2019-12-21 21:39:07

问题


I've got a EC2 / centOS vps, it's got postfix / sendmail for pushing out mail.

Now, the domain it self is set up on Google DNS, with it's mail records pointing to gmail servers. Gmail is used for primary email / smtp.

Back to the EC2, the ec2 does a weekly email... you can see where I'm going with this; Gmail / Yahoo / etc think the EC2 is a spam server, the from / reply to email is the correct domain, but the server's address / ip doesn't match the domain's MX record.

What's the best way to associate this?


回答1:


adding a second answer based on the comment from my first answer. You can request a Static IP (Elastic IP) from Amazon so you keep the same IP address all the time. This will allow you to use your instance for incoming emails (set the MX Record to your IP address). Next, you may need to send a request to Amazon to remove the SMTP mail sending limit. Finally, you need to tweak your SPF Record to confirm the email coming from your IP is actually coming from your domain. Once this is done, you should be ok. I say should... Email is an interesting "problem" to get around... but that should work...




回答2:


You can use Postfix to deliver your email though Gmail's SMTP server using the tutorial here. Another alternative, since your using EC2, is to use Amazon's SES service, which can also be used in conjunction with Postfix



来源:https://stackoverflow.com/questions/9929781/ec2-mail-via-gmail

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!