Jump to content

The ultimate community for Ruby on Rails developers.


Photo

Private Pub woes


  • Please log in to reply
2 replies to this topic

#1 Kelli Shaver

Kelli Shaver

    Inspector

  • Administrators
  • 75 posts
  • LocationKentucky

Posted 19 August 2013 - 06:54 PM

I ran into t his little problem over the weekend.

 

I was trying to use the Private Pub gem (railscast) and everything worked swimmingly in development. However, Publish_to would fail in production with Errno::ECONNREFUSED (Connection refused - connect(2)).

 

Now, I could load the faye.js file from the browser while in production just fine, but the controller couldn't connect to the Faye server (yes, I did specifically set my RAILS_ENV environment variable to 'production').

 

Thinking that Thin's default binding to 0.0.0.0 was the problem, I started Thin by binding it to the server's internal IP and still no dice (though the JS would still load from the browser). I even went so far as to open all TCP ports... still nothing.

 

I eventually gave up due to time constraints, but I'm very curious/frustrated that I couldn't figure this one out.

 



#2 james

james

    Guard

  • Moderators
  • 221 posts
  • LocationLeeds, U.K.

Posted 21 August 2013 - 12:14 AM

Errno::ECONNREFUSED (Connection refused - connect(2)) is usually a socket problem.

Do you have any log output for this error?

Whatever the issue is, it will be server specific, perhaps even needing to use the domain name instead of localhost but it's impossible to tell without more info. Hopefully you will have log entries


Programming is just about problem solving!


#3 Kelli Shaver

Kelli Shaver

    Inspector

  • Administrators
  • 75 posts
  • LocationKentucky

Posted 21 August 2013 - 07:16 AM

Unfortunately, that seems to be the extent of the error reporting. I tried it with both the domain name, the public IP and the internal IP. 

 

I'll have to go back and recreate it. Hopefully I'll get a chance to over the weekend and can give some more info.






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users