我在rails邮件服务器上遇到错误。最近,我的邮件工作正常,但昨天我又尝试发送电子邮件..我收到Completed 500 Internal Server Error in 30579ms
(Net::OpenTimeout (execution expired)
)错误。我已经搜索了一些可能的解决方案,但没有使用它。
Development.rb
config.action_mailer.perform_deliveries = true
config.action_mailer.raise_delivery_errors = true
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 => 25,
:domain => 'localhost:3000',
:user_name => 'my_email@gmail.com',
:password => 'my_password',
:authentication => :plain,
:enable_starttls_auto => true,
:tls => true
}