Skip to content

Commit

Permalink
Setup email via Sendgrid
Browse files Browse the repository at this point in the history
- Add sendgrid_api_key to credentials
- Configure action_mailer smtp settings
  • Loading branch information
mauriciofierrom committed Dec 8, 2023
1 parent 56ad928 commit 66558d1
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion config/credentials.yml.enc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
GOC1Lj07cHH4WjwXaJ07M+YxXFjTBBrDuitMit6p3bvW8PbKc91aOVEqh6X3728ZOO2JQ5Mx0WptJCkJCsquW/Ug/0I14YT7uHPKfgozTjtqmMFbyIQn0jp36bxHcpvaVJSaUvitbsaizUWduIlutPImzo0N2eZrIBZissbdCoadbUvbaescUEvZrfqg6LxXi0ZqX8HhkXMIPvLIAJhlmECrBSC2n3bM4RTY+1VyKAu3+O7pnfuEw0GFeptrwJ46I2tDldvJKZgtupjkzYrQ4kVnnpSbfUM8a7BJQKG6KblbtipUo/7pyKdbn5bNoxY9z1vLqFacz+DqreqMmSUO1110R5N3dpZYVPUCsc6sBDu5u3ex4A71IGAl5TPT1eqiOZl8ooStGfqXr30pgYMHOjUcj07xtfK0wDEJ--cnvAMQVqO0RplpHk--pDV/e55w3yPjxTjKLQh/8g==
amhyRa5LGqZ3C+qu5WasK3LhzFwVtFyZn7Bt9LQlkiHFn6/YNMiau0svHTbx7JrxSCX0d5pb27wvt/bzYeo34DvtQSDC2gLG3o/+XChVRpAH1HWqhA12w7PPOfWFpdb06ALoTpoqpOPwWPEMFGHd0MR2yWxrjZ28Cb7M2xykS2TIOyjRxGpZ3OLsaq+WC9kQHo/UNB9LoKdWe8IRVbD/MgHnjjQ5AcvuGH/hw2t9woXJG9P3UYEzz37ViaoRxIj7HkdO2fd+FKHXQcpNzNZLQPeZSvMp7B4c6t/e7351WuDFB303G3ZQ/MlfoT/aDXV2tK3gNDE9EnneQJk/tGtTTEApHb9CjI4ulyWqlJ3JfivcM0mlEeUXTYaFw6wLL6yOr0+DZOYLf7d9773uZXk1qBLBGRVsY19ErRvYK46662HQkvUY7YUwdCkyc4zGmf9DzsitBXWct7V5qs8f7c6HrOmHy0NkTCJt88/2WxM/hyhlIHSjMDIPuHKxs3ZfCkNA56CqkxeLE35CbFQk+A==--zYgqCm4mQtsocYj3--Anx2lttZVTqPfO1BzH23wA==
12 changes: 12 additions & 0 deletions config/environments/production.rb
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,18 @@
# config.active_job.queue_name_prefix = "along_production"

config.action_mailer.perform_caching = false
config.action_mailer.delivery_method = :smtp

config.action_mailer.smtp_settings = {
:user_name => 'apikey', # This is the string literal 'apikey', NOT the ID of your API key
:password => Rails.application.credentials.sendgrid_api_key, # This is the secret sendgrid API key which was issued during API key creation
:domain => "mauriciofierro.dev",
:address => "smtp.sendgrid.net",
:port => 587,
:authentication => :plain,
:enable_starttls_auto => true
}
}

# Ignore bad email addresses and do not raise email delivery errors.
# Set this to true and configure the email server for immediate delivery to raise delivery errors.
Expand Down

0 comments on commit 66558d1

Please sign in to comment.