Skip to content

Instantly share code, notes, and snippets.

@watson
Created February 27, 2011 08:54
Show Gist options
  • Save watson/846027 to your computer and use it in GitHub Desktop.
Save watson/846027 to your computer and use it in GitHub Desktop.
Setup SendGrid SMTP
class Mailer < ActionMailer::Base
def test
recipients "[email protected]"
from "[email protected]"
subject "Testing SendGrid"
end
end
config.action_mailer.raise_delivery_errors = true
config.action_mailer.delivery_method = :smtp
config.action_mailer.smtp_settings = {
:address => 'smtp.sendgrid.com',
:port => 25,
:domain => 'www.example.com',
:authentication => :login,
:user_name => 'email',
:password => 'secret'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment