Amazon Simple Email Server

We use Amazonโ€™s Simple Email Server to send outgoing emails from the Digital Collections.

The IAM identity we use to send email is:

ses-smtp-user.20200807-125501.

ย 

To get SMTP username and password, you use an AWS IAM credentials, but need to derive the password from the IAM secret key: https://docs.aws.amazon.com/ses/latest/dg/smtp-credentials.html#smtp-credentials-convert (ruby code: Convert AWS IAM credentials to AWS SMTP credentials )

(There may be another way to get them from SES consoleโ€ฆ for some reason accessing AWS SES console it makes us set up from scratch including verifying our domain, when in fact SES is already working for usโ€ฆ. not sure whatโ€™s going on here).

Settings in scihist_digicoll code

app/lib/scihist_digicoll/env.rb and config/environments/production.rb add the settings to the settings. To view them in the console, try:

Rails.application.config.action_mailer.smtp_settings
{:address=>"email-smtp.us-east-1.amazonaws.com",
:port=>587,
:user_name=>"joe",
:password=>"schmo",
:authentication=>:login,
:enable_starttls_auto=>true}

Sending a test email from the console

ActionMailer::Base.mail(from: 'no-reply@sciencehistory.org', to: 'erubeiz@sciencehistory.org', subject: 'Test message from Eddie. Please ignore.', content_type: 'text/html', body: 'Testing').deliver_now

DKIM

We started using DKIM to prove our ownership of the sciencehistory.org email domain in March 2024.

See settings in AWS .

See settings in Terraform.