-
Notifications
You must be signed in to change notification settings - Fork 6
Sending mail from aws instances
We can use SES to send mail from AWS instances to external recipients. This requires some work in AWS and some work in Nepho.
- Browse to the "SMTP Settings" portion of the SES console and click "Create My SMTP Credentials".
- Save these credentials for later reference.
- Make note of the SES SMTP server name appropriate to your region.
-
Make sure your deployment is using a pattern with SES support included (at the time of writing, only
single-host
andfull-monty
). Check this by making sure theSESSMTP
parameter is included:$ nepho -E <environment> show-params <deployment> | grep -A7 SESSMTP "SESSMTP": { "Default": "false", "Description": "Enable SES SMTP email?", "Type": "String", "AllowedValues": [ "false", "true" ],
-
If your deployment does not include SES support, add the following line to the
Parameters
stanza:{% include 'Parameters/SES-Parameters.json' %},
-
Populate your YAML config with the following parameters:
SESSMTP: "true" SESEndpoint: "<your SES SMTP server>" SESUsername: "<your SES SMTP user key>" SESPassword: "<your SES SMTP private key>" SESDomain: "devel.huit.harvard.edu"
-
Configure your application to send mail via the local MTA (e.g. by using the
sendmail
binary, or by SMTP tolocalhost
. If you're not using thesendmail
binary, make sure you configure your sender address to be<somebody>@devel.huit.harvard.edu
.
At this point you should be able to send mail to arbitrary external destinations. Don't make us regret this.