Women in Technology

Hear us Roar



Article:
  Location, Location, Location: Tips for Storing Web Site Files
Subject:   Visiting your virtual sites from another computer
Date:   2004-02-17 21:49:47
From:   rmcgonegal
Response to: Visiting your virtual sites from another computer

Getting Apache working on just my Mac wasn't too hard. But trying to make test domains resolve from other computers does not work so far for me.


I don't know what version you are using but if I try to add


NameVirtualHost 127.0.0.1 192.168.1.100


to httpd.conf, then loading Apache errors out with the message


NameVirtualHost takes one argument, A numeric IP address:port, or the name of a host


It will load if I take out the localhost IP so it reads


NameVirtualHost 192.168.1.100


But then using your recommendation with multiple development sites such as


<VirtualHost test.icalshare.com 192.168.1.100>
...
</VirtualHost>


<VirtualHost test.icalshare2.com 192.168.1.100>
...
</VirtualHost>


produces the error


[warn] VirtualHost 192.168.1.100:80 overlaps with VirtualHost 192.168.1.100:80, the first has precedence, perhaps you need a NameVirtualHost directive


If I eliminate the IP so it is just name based VirtualHost,


<VirtualHost test.iCalshare.com>


then it works fine on my Mac. But not from PCs on the LAN. It's great to run cgi's and Php, but being able to test all this on a local PC would be a huge help.


Do I need to run a DNS server? Bind is on the Mac but I don't know if it really needs a dedicated machine. And it sounds like overkill (I've only got 2 Macs and 2 PCs).


Does anyone know of a solution? A tutorial on intranets would be great.

Full Threads Newest First

Showing messages 1 through 2 of 2.

  • I can't get this to work!!!
    2004-04-10 22:34:14  bcamp [View]

    This is EXACTLY what i'm looking for right now. Want to be able to test my sites via my VirtualPC install as well as local mac browsers. This tip doesn't work for me tho. When i tried to stop/restart apache it hangs. Giong back and removing the above edits allows it to start normally. Anyone have any other hints???
    • I can't get this to work!!!
      2009-08-30 14:01:15  TEITCU [View]

      If you use either a text editor or vi to /etc/httpd/conf.d/system-config-httpd.conf. Go down to your virtualhost lines and make sure that each one of them ready <VirtualHost *:80>. Each one should read like this.