Rails : Error Message: end of file reached
Hi,
I am trying to send an email using ZOHO credentials from the rails application. For this I have used SSL certificate for my application. When I trying to sending an email, getting following error.
- Could not send email to MY_EMAIL_ID
- Error Message: end of file reached
- /home/parthiv/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/openssl/buffering.rb:174:in `sysread_nonblock'
- /home/parthiv/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/openssl/buffering.rb:174:in `read_nonblock'
- /home/parthiv/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/net/protocol.rb:153:in `rbuf_fill'
- /home/parthiv/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/net/protocol.rb:134:in `readuntil'
- /home/parthiv/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/net/protocol.rb:144:in `readline'
production.rb
My zoho credentials are
- config.action_mailer.smtp_settings = {
- address: "smtp.zoho.com",
- port: 465,
- domain: "MY_DOMAIN_NAME",
- user_name: "ZOHO_EMAIL_ID",
- password: "ZOHO_PASSWORD",
- authentication: :plain,
- ssl: true,
- tls: true,
- enable_starttls_auto: true
- }
I have changed the value of
config.mailer_sender in config/initializers/devise.rb but no luck.
Changed
- config.mailer_sender = Settings.try(:mail).try(:from)
to
- config.mailer_sender = 'ZOHO_EMAIL'