carbon_aws_ses_adapter

Version, currently 1.13 versions

github.com/keizo3/carbon_aws_ses_adapter

An email adapter for Amazon SES that integrates with Carbon

4 stars
0 dependents
License: MIT

Nothing has been indexed for 1.1 yet. The tag is recorded, its shard.yml has not been read, so the manifest and dependency list below are empty because they are unknown rather than because they are absent.

Installation

# Add this to your shard.yml
dependencies:
  carbon_aws_ses_adapter:
    github: keizo3/carbon_aws_ses_adapter
    version: ~> 1.1

Then run:

shards install

shard.yml

No shard.yml has been indexed for 1.1. You can read it on the repository.

Dependencies

Unknown: the shard.yml for this version has not been read yet.

README

This README is the one indexed from the repository at its latest ref, not from the tag for this version.

Carbon AWS SES Adapter

Build Status

This is luckyframework/carbon's adapter for AWS SES (Simple Email Service)

https://github.com/luckyframework/carbon

Installation

Add this to your application's shard.yml:

dependencies:
  carbon_aws_ses_adapter:
    github: keizo3/carbon_aws_ses_adapter

Add this to your application's shards.cr:

require "carbon_aws_ses_adapter"

Usage

Configure AWS SES Simple Email Service

  1. Go to the Amazon Web Services developer console.
  2. Ensure that AWS SES is correctly set up according to the documentation.
  3. Create an AWS IAM user who can send emails. The user must have at least the following permissions:
    • ses:SendEmail
    • ses:SendRawEmail
  4. Copy the AWS Access Key and AWS Secret Access key for the IAM user you've created.
  5. Set up the adapter in Lucky via the config/email.cr file.

Configure the mailer class

# config/email.cr

BaseEmail.configure do
  settings.adapter = Carbon::AwsSesAdapter.new(
    key:    ENV["AWS_SES_ACCESS_KEY"],
    secret: ENV["AWS_SES_SECRET_KEY_KEY"],
    region: ENV["AWS_SES_REGION"]
  )
end

Development

  • shards install
  • Make changes
  • crystal spec (will skip sending test emails to AWS SES)
  • crystal spec -D send_real_email (will send real emails, and requires the below .env file content)
# In .env
# If you want to run tests that actually test emails against the AWS SES
AWS_SES_ACCESS_KEY=get_from_aws_ses_key
AWS_SES_SECRET_KEY=get_from_aws_ses_secret
AWS_SES_REGION=get_from_aws_ses_region
AWS_SES_FROM_ADDRESS=verified_address
AWS_SES_TO_ADDRESS=recipient_address

Contributing

  1. Fork it ( https://github.com/keizo3/carbon_aws_ses_adapter )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Make your changes
  4. Run ./bin/test to run the specs, build shards, and check formatting
  5. Commit your changes (git commit -am 'Add some feature')
  6. Push to the branch (git push origin my-new-feature)
  7. Create a new Pull Request

Contributors

  • keizo3 - creator, maintainer