【发布时间】:2012-03-21 21:28:43
【问题描述】:
我的 heroku 应用程序有问题,我正在尝试使用我的 Godaddy 电子邮件帐户发送电子邮件,这是我在 environment/production.rb 中的设置:
config.active_support.deprecation = :notify
config.action_mailer.default_url_options = { :host => 'coursebuilder2.heroku.com' }
config.action_mailer.delivery_method = :smtp
ActionMailer::Base.smtp_settings = {
:address => "smtpout.secureserver.net",
:port => 25,
:user_name => "myemail@domain.com",
:password => "password",
:authentication => :login
}
config.action_mailer.raise_delivery_errors = true
但是,这是我得到的:
Rendered instructors/mailer/confirmation_instructions.html.erb (1.1ms)
Completed 500 Internal Server Error in 666ms
SocketError (getaddrinfo: Name or service not known):
cache: [POST /instructors] invalidate, pass
那么,我在这里缺少什么?
编辑
我已经修复了上面的设置,但是现在我在下面出现了超时错误:
2012-03-04T04:44:20+00:00 app[web.1]: Rendered instructors/mailer/confirmation_instructions.html.erb (0.4ms)
2012-03-04T04:44:50+00:00 heroku[router]: Error H12 (Request timeout) -> POST coursebuilder2.herokuapp.com/instructors dyno=web.1 queue= wait= service=30000ms status=503 bytes=0
2012-03-04T04:45:20+00:00 app[web.1]: Completed 500 Internal Server Error in 60414ms
2012-03-04T04:45:20+00:00 app[web.1]:
2012-03-04T04:45:20+00:00 app[web.1]:
2012-03-04T04:45:20+00:00 app[web.1]: Timeout::Error (Timeout::Error):
2012-03-04T04:45:20+00:00 app[web.1]:
2012-03-04T04:45:20+00:00 app[web.1]:
2012-03-04T04:45:20+00:00 app[web.1]: cache: [POST /instructors] invalidate, pass
谁能给点建议?
【问题讨论】:
标签: ruby-on-rails-3 heroku actionmailer