23

I have a hard time understanding how I could setup e-mail forwarding on Amazon EC2 for my own domain, meaning how I can forward every email sent to ...@mydomain.com to my personal email address.

I'm using Amazon SES for sending emails. But what about incoming e-mails - is there any simpler way than setting up a complete e-mail server? As I'm using IP forwarding for my domain, I can't set up email forwarding with my domain provider.

I know this is kind of a general question.. I'd appreciate any help that points me in the right direction!

SPi
  • 912
  • 2
  • 12
  • 26
  • Don't even bother with all of that, try https://www.migadu.com and don't waste money and time on "emails" – SudoPlz Dec 16 '18 at 01:30

4 Answers4

16

Currently there is no incoming email (POP, IMAP, etc) managed service from AWS, so you'd need to set up your own mail receiving and forwarding.

Using Postfix as a mail server, setup would look like this: http://www.cyberciti.biz/faq/linux-unix-bsd-postfix-forward-email-to-another-account/

If forwarding is all you need, you could set up a email service outside AWS (Google Apps?) and redirect using GMail rules, for example.

UPDATE: Amazon Web Services has announced WorkMail as a email and calendaring service. http://aws.amazon.com/workmail/

UPDATE: Amazon SES now supports inbound mail

Julio Faerman
  • 12,021
  • 9
  • 52
  • 72
  • 2
    Amazon uses something called WorkMail now – TheBlackBenzKid Mar 17 '15 at 14:42
  • 1
    @TheBlackBenzKid However that only works with Outlook / via AD, no POP or IMAP :( – Tobias Kienzler May 24 '15 at 18:05
  • 7
    WorkMail is **4 USD / User / Month**.. Is there any free solution to forward mails? – Yves M. Dec 22 '15 at 20:14
  • 1
    What about Amazon SES? – Daniele Orlando Mar 17 '16 at 23:44
  • 1
    As mentioned by an AWS team member [here](http://sesblog.amazon.com/post/Tx3HQEJUJNVABG8/Receiving-Email-with-Amazon-SES), there is no simple setup to use Amazon SES to forward emails (see "You are correct, SES does not currently support a mail relay action"). I've found [this](https://github.com/arithmetric/aws-lambda-ses-forwarder), an AWS Lambda script that uses SES to forward emails, but I've yet to try it. – Greg Sadetsky Jun 02 '16 at 21:58
16

Use a mail forwarding service. Eg. improvmx.com

It allows you to forward emails directed at your domain to any email address of your choice. All you have to do is add an MX record for your domain to point to improvmx.

And its free.

Cyril N.
  • 35,568
  • 34
  • 119
  • 213
Rommel Dongre
  • 169
  • 1
  • 2
  • 1
    Whereas improvmx.com may be a great product, this is not really answering the question. The OP is specifically asking about an EC2 instance on AWS. – Jim Aug 06 '18 at 10:59
  • @bersling could you expand on what your mean? If you later decide to use a different email forwarder what would happen? – Harry Moreno Sep 01 '18 at 21:44
  • with a different one it would work, but in improvmx you can't change the forwarding once it's set. maybe this has changed in the mean time though. – bersling Sep 19 '18 at 11:50
  • 1
    [ImprovMX](https://improvmx.com) recently pushed a new version of their service. You can now change your email address and even add custom aliases for all of your domain. – Cyril N. Nov 08 '18 at 16:37
9

SES + Lambda for email redirections

This guy made up a lambda function to redirect emails received via amazon SES. There are detailed instructions on the readme

https://github.com/arithmetric/aws-lambda-ses-forwarder

Cyril Duchon-Doris
  • 10,472
  • 6
  • 59
  • 124
  • 1
    this looked good but hasn't been kept upto date. Similar solutions also at https://github.com/serverless/serverless search for `SES` or `email`. – Harry Moreno Sep 04 '18 at 16:37
  • Well I am running this lambda ses forwarder code for one of my own domains, it's been working well so far. – Cyril Duchon-Doris Sep 04 '18 at 20:27
  • could you update step 2? with a preset policy offered from amazon if possible? that's where I'm stuck – Harry Moreno Sep 05 '18 at 20:43
  • You need to configure your S3 bucket `"Resource": "arn:aws:s3:::S3-BUCKET-NAME/*"` so unless you want to use preset policy giving access to everything, I'm not sure you want a preset policy... – Cyril Duchon-Doris Dec 22 '18 at 12:38
-1

You can create a forwarder rule in WorkMail. It requires logging in as the end user to create. Step by step here. Note that forwarding in this way changes the header of the email to look like the end user sent it instead of actual source. Not ideal.

SeanFromIT
  • 499
  • 1
  • 8
  • 17