Views: 3920
I would love to do this serverless, But still here is a way to use AWS S3 to receive email on behalf of your domain.
One could setup the domain in SES and receive for any number of users, but still an EC2 Server would be required.
A possible advantage is that Spammers can’t get hold of your SMTP server if it doesn’t exist.
Dovecot reads from MBOX directory regardless of whether you use exim, sendmail of postfix. So you could have NONE of these. You replace them with scripts that copy the messages from S3 to your EC2 server with Dovecot .
Here is how to use Amazon and any virtual server to deliver email from SES to a local IMAP account. This plan is about stable operations: every step is under our control. Have SES receive emails And deliver to an S3 bucket and send notification to a SNS topic Subscribe to that notification with HTTPS protocol Use aws/aws-php-sns-message-validator and write a small PHP script to reveive notifications from SNS through HTTPS SNS only sends messaged ID-s, put those in a file Install incron on your server to st
- Have SES receive emails
- And deliver to an S3 bucket and send notification to a SNS topic
- Subscribe to that notification with HTTPS protocol
- Use aws/aws-php-sns-message-validator and write a small PHP script to reveive notifications from SNS through HTTPS
- SNS only sends messaged ID-s, put those in a file
- Install incron on your server to start a shell script that downloads those messages from the S3 bucket by s3cmd and delivers to the local IMAP account by sendmail
- Use any IMAP server, I use Courier IMAP
- Read your messages with e.g. Rainloop webmail
- Use SES also for sending outgoing emails
Source: How to implement inbound email on Amazon AWS? – Stack Overflow