The Amazon Simple Email Service Scripts are used for interfacing with the Amazon Simple Email Service (SES)

The Amazon Simple Email Service Scripts requires Perl 5.6.0 or greater the following modules:

  • Digest::SHA
  • URI::Escape
  • Mozilla::CA
  • Bundle::LWP
  • LWP::Protocol::https
  • MIME::Base64
  • Crypt::SSLeay
  • XML::LibXML

and requires the following environment variables to be set:

This article will set the environment variable AWS_SES_HOME to be consistent with AWS CLI tools.

Install Script

If you’re running Linux, this script will do everything this article covers: install_ses.sh from our aws_scripts collection. Be sure to run it as root or use sudo.

Git Repository

Checkout the repository. This only needs to be done once throughout this series of articles.

Console - user@hostname ~ $

1
git clone https://bitbucket.org/dowdandassociates/aws_scripts.git

Run install script

Console - user@hostname ~ $

1
sudo aws_scripts/install_aws_cli/install_ses.sh

Direct Download of Script

Console - user@hostname ~ $

1
curl -L https://bitbucket.org/dowdandassociates/aws_scripts/raw/master/install_aws_cli/install_ses.sh | sudo bash

Install Process

Create the directory in which to download the software if it does not already exist.

Console - root@hostname ~ #

1
mkdir -p /tmp/aws

Create the directory in which to install the software if it does not already exist

Console - root@hostname ~ #

1
mkdir -p /opt/aws

Download the software.

Console - root@hostname ~ #

1
2
3
4
curl \
--silent \
--output /tmp/aws/ses-tools.zip \
http://d36cz9buwru1tt.cloudfront.net/catalog/attachments/ses-tools-2012-05-15.zip

Delete any previous unzips of the software that may exist.

Console - root@hostname ~ #

1
rm -fR /tmp/aws/ses-tools

Unzip the software.

Console - root@hostname ~ #

1
2
mkdir -p /tmp/aws/ses-tools
unzip -d /tmp/aws/ses-tools /tmp/aws/ses-tools.zip

Delete any previously installed versions.

Console - root@hostname ~ #

1
rm -fR /opt/aws/ses-tools

Move the unzipped directory into the install directory.

Console - root@hostname ~ #

1
mv /tmp/aws/ses-tools /opt/aws/ses-tools

Delete the .zip file.

Console - root@hostname ~ #

1
rm -f /tmp/aws/ses-tools.zip

Set AWS_SES_HOME, and put the tools into the path.

Console - root@hostname ~ #

1
2
3
4
cat <<'EOF'>/etc/profile.d/ses-tools.sh
export AWS_SES_HOME=/opt/aws/ses-tools
export PATH=$PATH:$AWS_SES_HOME/bin
EOF

References

Parts in this series