I am trying to send emails via actionmailer. It was working fine before and now suddenly what was working is no longer working! I have one version of the application running in production and whenever I try to run it in production I get the error No connection could be made because the target machine actively refused it. - connect(2) (see details in the attached text file) Now when I try to run the same application on the local machine (Dev) with a local mail server running on it I get the error : Net::SMTPAuthenticationError in AccessrequestsController#create 535 Authentication Failed (see details in the text file attached). The actionmailer settings for production are : ActionMailer::Base.smtp_settings = { :address => "localhost", :port => 25, :domain => "letter4sure.com", :authentication => :login, :user_name => "CHECKED_THIS_ADMIN_USER/PWD_IT_WORKS", :password => "CHECKED_THIS_ADMIN_USER/PWD_IT_WORKS" } For the local machine it is : ActionMailer::Base.smtp_settings = { :address => "localhost", :port => 25, :domain => "localhost", :authentication => :login, :user_name => "CHECKED_THIS_ADMIN_USER/PWD_IT_WORKS", :password => "CHECKED_THIS_ADMIN_USER/PWD_IT_WORKS" } When I remove all authentication user name and password information I can send emails beautifully but that is BAD! because my mail server could be used as a relaying station. That is unacceptable. So help would be appreciated in deciphering the mysteries of ActionMailer please. -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Ather Shiraz
2008-Jun-24 00:02 UTC
Re: ActionMailer Fails To Send Emails Post Authentication
Ok I figured out the problem or atleast I think I did. I have to create a separate account with user and password (NOT admin) that can send emails. then the following works ... atleast for now. Ather Shiraz wrote:> I am trying to send emails via actionmailer. > > It was working fine before and now suddenly what was working is no > longer working! > > Now when I try to run the same application on the local machine (Dev) > with a local mail server running on it I get the error : > > Net::SMTPAuthenticationError in AccessrequestsController#create > 535 Authentication Failed (see details in the text file attached). > > The actionmailer settings for production are : > ActionMailer::Base.smtp_settings = { > :address => "localhost", > :port => 25, > :domain => "letter4sure.com", > :authentication => :login, > :user_name => "CHECKED_THIS_ADMIN_USER/PWD_IT_WORKS", > :password => "CHECKED_THIS_ADMIN_USER/PWD_IT_WORKS" > } >-- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---