[英]EOFError - end of file reached when using Zoho mail
I am using Zoho mail to send email from my Rails application.我正在使用 Zoho 邮件从我的 Rails 应用程序发送 email。 But I am getting EOFError - end of file reached
error when trying to send email.但是我收到EOFError - end of file reached
错误。 Below is my configuration for development.rb
下面是我对development.rb
的配置
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.zoho.com",
:port => 465,
:user_name => 'info@mydomainname.com',
:password => 'zoho_mail_password',
:authentication => :login,
:ssl => true,
:tls => true,
:enable_starttls_auto => true
}
Here is error from my log file这是我的日志文件中的错误
Completed 500 Internal Server Error in 7481ms (ActiveRecord: 2.1ms | Allocations: 44097)
EOFError - end of file reached:
app/controllers/users_controller.rb:19:in `create'
Please help.请帮忙。
I managed to solve the problem.我设法解决了这个问题。 I had to set the default address in application_mailer.rb
file我必须在application_mailer.rb
文件中设置默认地址
default from: 'Business Name <info@mydomainname.com>'
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.