SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Member
    Join Date
    Mar 2002
    Posts
    11
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Localhost vs 0.0.0.0 for Rails development

    On my Mac at home, I've been accessing the app that I've been building with "Simply Rails 2" at localhost.

    Never been a problem

    I'm using my brother-in-law's Mac temporarily to progress the project. On his Mac, I can access the app at 0.0.0.0, but not at localhost or 127.0.0.1

    It's not a deal breaker, but I'm curious. What could be happening here?

    Both are running Mac OS X 10.5

    (All on port 3000. URLs are truncated because the forum software doesn't me to submit links.)

  2. #2
    Programming Team silver trophybronze trophy
    Mittineague's Avatar
    Join Date
    Jul 2005
    Location
    West Springfield, Massachusetts
    Posts
    17,186
    Mentioned
    191 Post(s)
    Tagged
    2 Thread(s)
    Are you both using the same server? I seem to remember somewhere that one didn't use the usual numbers. Maybe he's using that one? Or maybe his configuration is that way on purpose / by accident?

  3. #3
    SitePoint Member
    Join Date
    Mar 2002
    Posts
    11
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Using Mongrel on both his Mac and mine. Not a biggy -- i'll just type out the zero dot zero dot... each time. :-) Mostly just curious.

  4. #4
    Programming Team silver trophybronze trophy
    Mittineague's Avatar
    Join Date
    Jul 2005
    Location
    West Springfield, Massachusetts
    Posts
    17,186
    Mentioned
    191 Post(s)
    Tagged
    2 Thread(s)
    Maybe you have an older version of something. A grep for 0.0.0.0 turned up a lot of hits. In Ruby 1.8 the gems/rails-2.1.0/lib/commands/servers/ mongrel.rb file has
    Code Ruby:
    OPTIONS = {
      :port        => 3000,
      :ip          => "0.0.0.0",
      :environment => (ENV['RAILS_ENV'] || "development").dup,
      :detach      => false,
      :debugger    => false
    }
    and the gems/actionpack-2.1.0 changelog file has
    * Changed test requests to come from 0.0.0.0 instead of 127.0.0.1 such that they don't trigger debugging screens on exceptions, but instead call rescue_action_in_public
    Maybe you have an older version? Or the way Ruby changes so fast, maybe you have a newer version where it's changed back


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •