Hi, i am running a rails web application on freebsd. I am having troubles sending emails. i have this: ActionMailer::Base.server_settings = { :address => ''smtp.mydomain.com'', :domain => ''mydomain.com'', :port => 25, :user_name => ''user'', :password => ''password'', :authentication=>:login } in environment.rb. When i send an email through rails nothing happens. What else do i need to do? -- Posted via http://www.ruby-forum.com/.
Check that your environment specific config doesn''t have the following line in it: config.action_mailer.delivery_method = :test Or else the email will be routed to the corresponding log file. This generally only applies to the test environment, but I wanted to point it out (check development.rb). -----Original Message----- From: rails-bounces@lists.rubyonrails.org [mailto:rails-bounces@lists.rubyonrails.org] On Behalf Of Raj Kapila Sent: Thursday, July 27, 2006 5:54 PM To: rails@lists.rubyonrails.org Subject: [Rails] sending emails Hi, i am running a rails web application on freebsd. I am having troubles sending emails. i have this: ActionMailer::Base.server_settings = { :address => ''smtp.mydomain.com'', :domain => ''mydomain.com'', :port => 25, :user_name => ''user'', :password => ''password'', :authentication=>:login } in environment.rb. When i send an email through rails nothing happens. What else do i need to do? -- Posted via http://www.ruby-forum.com/. _______________________________________________ Rails mailing list Rails@lists.rubyonrails.org http://lists.rubyonrails.org/mailman/listinfo/rails
Dennis Baldwin wrote:> Check that your environment specific config doesn''t have the following > line in it: > > config.action_mailer.delivery_method = :test >thats not there but i turned error messages on and i get: /usr/local/lib/ruby/1.8/timeout.rb:54:in `new'' /usr/local/lib/ruby/1.8/net/protocol.rb:206:in `old_open'' /usr/local/lib/ruby/1.8/timeout.rb:56:in `timeout'' /usr/local/lib/ruby/1.8/timeout.rb:76:in `timeout'' /usr/local/lib/ruby/1.8/net/protocol.rb:206:in `old_open'' /usr/local/lib/ruby/1.8/net/smtp.rb:393:in `do_start'' /usr/local/lib/ruby/1.8/net/smtp.rb:378:in `start'' /usr/local/lib/ruby/1.8/net/smtp.rb:316:in `start'' /usr/local/lib/ruby/gems/1.8/gems/actionmailer-1.2.1/lib/action_mailer/base.rb:447:in `perform_delivery_smtp'' /usr/local/lib/ruby/gems/1.8/gems/actionmailer-1.2.1/lib/action_mailer/base.rb:333:in `deliver!'' /usr/local/lib/ruby/gems/1.8/gems/actionmailer-1.2.1/lib/action_mailer/base.rb:227:in `method_missing'' #{RAILS_ROOT}/app/controllers/coders_controller.rb:43:in `create'' -- Posted via http://www.ruby-forum.com/.
i get his error when using ActionMailer: /usr/local/lib/ruby/1.8/timeout.rb:54:in `new'' /usr/local/lib/ruby/1.8/net/protocol.rb:206:in `old_open'' /usr/local/lib/ruby/1.8/timeout.rb:56:in `timeout'' /usr/local/lib/ruby/1.8/timeout.rb:76:in `timeout'' /usr/local/lib/ruby/1.8/net/protocol.rb:206:in `old_open'' /usr/local/lib/ruby/1.8/net/smtp.rb:393:in `do_start'' /usr/local/lib/ruby/1.8/net/smtp.rb:378:in `start'' /usr/local/lib/ruby/1.8/net/smtp.rb:316:in `start'' /usr/local/lib/ruby/gems/1.8/gems/actionmailer-1.2.1/lib/action_mailer/base.rb:447:in `perform_delivery_smtp'' /usr/local/lib/ruby/gems/1.8/gems/actionmailer-1.2.1/lib/action_mailer/base.rb:333:in `deliver!'' /usr/local/lib/ruby/gems/1.8/gems/actionmailer-1.2.1/lib/action_mailer/base.rb:227:in `method_missing'' #{RAILS_ROOT}/app/controllers/coders_controller.rb:43:in `create'' in development.rb ActionMailer::Base.server_settings = { :address => ''smtp.mydomain.com'', :domain => ''mydomain.com'', :port => 25, :user_name => ''user'', :password => ''password'', :authentication=>:login } -- Posted via http://www.ruby-forum.com/.
Raj Kapila wrote:> i get his error when using ActionMailer: > > > /usr/local/lib/ruby/1.8/timeout.rb:54:in `new'' > /usr/local/lib/ruby/1.8/net/protocol.rb:206:in `old_open'' > /usr/local/lib/ruby/1.8/timeout.rb:56:in `timeout'' > /usr/local/lib/ruby/1.8/timeout.rb:76:in `timeout'' > /usr/local/lib/ruby/1.8/net/protocol.rb:206:in `old_open'' > /usr/local/lib/ruby/1.8/net/smtp.rb:393:in `do_start'' > /usr/local/lib/ruby/1.8/net/smtp.rb:378:in `start'' > /usr/local/lib/ruby/1.8/net/smtp.rb:316:in `start''Looks like your SMTP server timed out -- Posted via http://www.ruby-forum.com/.