- Descomente
#Include /private/etc/apache2/extra/httpd-vhosts.conf
em/etc/apache2/httpd.conf
- Adicione
127.0.0.1 test.dev
a/etc/hosts
-
Salvar como
/etc/apache2/users/username.conf
:<Directory "/Users/username/Sites"> Options Indexes MultiViews AllowOverride All Order allow,deny Allow from all </Directory> <VirtualHost *:80> ServerName test.dev DocumentRoot /Users/username/Sites/test </VirtualHost> <VirtualHost *:80> ServerName localhost DocumentRoot /Users/username/Sites </VirtualHost>
-
Executar
sudo apachectl restart