Réglage VirtualHost sur OSX 10.7 (Lion)

J'ai finalement changé de Lion, Mais j'ai des problèmes avec le réglage Apache VirtualHost. C'est ce que j'ai fait jusqu'à présent, et je ne sais pas pourquoi cela ne fonctionne pas.

1) DANS /etc/apache2/httpd.conf J'ai désabonné cette ligne:

Include /private/etc/apache2/extra/httpd-vhosts.conf

2) DANS httpd-vhosts.conf Je l'ai mis:

NameVirtualHost *:80    

<virtualhost *:80="">
ServerName localhost
DocumentRoot "/Library/WebServer/Documents"
</virtualhost>
<virtualhost *:80="">
ServerName work.local
DocumentRoot "/Users/me/Work"
<directory me="" users="" work="">
Order allow,deny
Allow from all
</directory>
</virtualhost>

3) Puis j'ai créé index.html dans ~ / Work

4) Finalement je.

sudo apachectl restart

(Je le redémarre aussi de partagé dans Sys Preference)

... Mais quand je vais à work.local, Il ne peut pas le trouver et je ne peux pas le propager.

$ ping work.local
ping: cannot resolve work.local: Unknown host


$ apachectl -S
httpd: Could not reliably determine the server's fully qualified domain name, using me-iMac.local for ServerName
VirtualHost configuration:
wildcard NameVirtualHosts and _default_ servers:
*:80 is a NameVirtualHost
default server localhost (/etc/apache2/other/httpd-vhosts.conf:17)
port 80 namevhost localhost (/etc/apache2/other/httpd-vhosts.conf:17)
Syntax OK
Invité:

Christine

Confirmation de:

$ ping work.local

ping: Incapable d'autoriser work.local: Hôte inconnu

Le système n'a pas IP Adresses work.local

Ajouter work.local comme nom d'hôte dans / etc / hosts

Voir EUT. c'est pour dsn sur lion.
http://www.justincarmony.com/b ... tion/

Pour répondre aux questions, connectez-vous ou registre