ruby - SMTP settings using Godaddy mail with Rails 3 -
how should set smtp settings in initializer file using godaddy mail?
shamelessly taken article here: http://pilotoutlook.wordpress.com/2008/10/13/setup-email-in-ruby-on-rails-using-godaddysmtp/
open root/config/environment.rb
file sendmail, add following lines -
actionmailer::base.delivery_method = :sendmail actionmailer::base.smtp_settings = { :domain => ‘www.example.com’ }
for godaddy, add following lines -
actionmailer::base.delivery_method = :smtp actionmailer::base.smtp_settings = { :address => ‘smtpout.secureserver.net’, :domain => ‘www.example.com’, :port => 80, :user_name => ‘johndoe@example.com’, :password => ‘yourpassword’, :authentication => :plain }
save , restart webserver. set.
remember can send 300 emails per day godaddy, if need send more emails, have use sendmail or other solution.
note port not set 25 - on purpose. godaddy's email servers configured use several ports, in case 25 blocked.
Comments
Post a Comment