Adding Virtual Sites to Apache Easily

I use Apache locally on my Macbook and my Asus EEE (Ubuntu) to develop against.

We still use Apache for some of our webservices here at Lookery; we’re slowly but surely moving to Nginx as our standard. I created a simple shell script to make adding new virtual sites to your development Apache install easier.

The script is called addsite you can find it my personal Git repo here.

Example use:

dcancel@ubuntu:~/$ sudo ./addsite xyz
Adding site to /etc/hosts: xyz.local
Adding the new site to apache: xyz
Site xyz installed; run /etc/init.d/apache2 reload to enable.

* Reloading web server config apache2 [ OK ]
********************************** Visit your new site at: xyz.local **********************************

- David


Done reading? subscribe: To get an automatic feed of all future posts subscribe here.
Link to This Post:  
Tags: ,
Posted in Uncategorized | Share/Save/E-mail

blog comments powered by Disqus You can leave a response, or trackback from your own site.


Subscribe to our RSS Feed

Recent Posts

Archive

Post Categories

Recent Readers


What We're Reading