when I try to send an email via sendgrid on heroku cedar stack, I got an following error :
ArgumentError (SMTP-AUTH requested but missing user name):
my settings in /environments/staging.rb are :
config.action_mailer.delivery_method = :smtp
config.action_mailer.raise_delivery_errors = true
config.action_mailer.default_url_options = { :host => 'myapp' }
ActionMailer::Base.smtp_settings = {
:address => "smtp.sendgrid.net",
:port => "587",
:authentication => :plain,
:user_name => ENV['SENDGRID_USERNAME'],
:password => ENV['SENDGRID_PASSWORD'],
:domain => 'heroku.com'
}
My Sendgrid password/username are obtained from Heroku according to this page
Does anyone have any suggestion ?