问题
I'm having an issue properly setting up my web application to use Windows Live Hosted email instead of the normal Google Apps Email. This is due to the fact that Google is down charging for such services.
I've entered in the proper config.action_mailer.smtp_settings, but for some reason I can't get email notifications to properly send. My config below, if I swap the config with another Google Apps config settings email, it's functional. Am I missing something?
config.action_mailer.smtp_settings = {
:enable_starttls_auto => true,
:address => "smtp.live.com",
:port => "587",
:domain => "mail.live.com",
:user_name => "###########.net",
:password => "###########",
:authentication => :plain
}
This is the error I am receiving. getaddrinfo: nodename nor servname provided, or not known
回答1:
here is my configuration:
config.action_mailer.smtp_settings = {
:address => "smtp.live.com",
:port => 587,
:domain => 'example.com',
:user_name => 'XXXXXXXXX',
:password => 'XXXXXXXXX',
:authentication => 'plain',
:enable_starttls_auto => true }
The only difference is the authentication.
Also remember this line
config.action_mailer.default_url_options = { :host => 'localhost:3000' }
来源:https://stackoverflow.com/questions/13810580/rails-3-smtp-settings-for-hotmail-live-hosted-email