Skip to content

Instantly share code, notes, and snippets.

@danlefebvre
Created April 4, 2012 04:11
Show Gist options
  • Save danlefebvre/2297647 to your computer and use it in GitHub Desktop.
Save danlefebvre/2297647 to your computer and use it in GitHub Desktop.
Adding Virtual host Ubuntu
cd /etc/apache2/sites-available
sudo pico yourdomain.dev.conf
<VirtualHost *:80>
ServerName yourdomain.dev
DocumentRoot /home/dev/sites/yourdomain
</VirtualHost>
sudo pico /etc/hosts
127.0.0.1 yourdomain.dev
sudo a2ensite yourdomain.dev.conf
sudo /etc/init.d/apache2 reload
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment