Reputation: 1811
I am using devise which is sending confirmation email. I am not sure what it is doing, but I can see in the output of 'rails s' that mail is sent to correct emails.
config/environments/development.rb:
config.action_mailer.default_url_options = { :host => 'localhost:3000' }
config.action_mailer.delivery_method = :smtp
config.action_mailer.smtp_settings = {
address: 'smtp.gmail.com',
port: 587,
domain: 'localhost:3000',
username: '[email protected]',
password: 'pwd',
authentication: 'plain',
enable_starttls_auto: true
}
I have seen many stackoverflow questions but everything showing this config only and this is not workng for me .
Upvotes: 0
Views: 744
Reputation: 3361
Its user_name but not username. Observer the underscore.
Also note that, domain is 'optional', so you can remove it.
And, set this (false by default):
config.action_mailer.raise_delivery_errors = true
if you want to see delivery errors
Upvotes: 1