Access Apache VirtualHost from any computer on the local network?

I have a Wamp setting with quite a few website settings as virtual hosts such as httpd.conf

<VirtualHost 127.0.0.1>
    ServerName project1.local
    DocumentRoot "c:/wamp/project1/"
</VirtualHost>

I have this data in the host file of the Wamp machine, and I can only access it on this computer.

127.0.0.1 project1.local

However, when I try to put a record on my OSX computer, since (192.168.1.101 is the internal ip machine for the machine), it will not pull the page up.

192.168.1.101 project1.local

Is there anything else I need to do to make this work from other machines? Thank!

+5
source share
2 answers

<VirtualHost 192.168.1.101> ( 127.0.0.1), <VirtualHost *>, VH .

+4


,
  "Client_IP" - IP- , , - IP- , - , 'servername/'.

<VirtualHost *:80>
   ServerName servername
   DocumentRoot d:\wamp\www\dir_name                        

    <Directory "d:\wamp\www\dir_name">                             
       Order Allow,Deny
       Allow from 127.0.0.1 Client_IP
    </Directory>
 </VirtualHost>

, Apache, ,

server_ip servername 

c:/windows/system32/drivers/etc/hosts.

0

All Articles