Virtual Hosts with Apache2 on Ubuntu 8.04

May 5th 2008

I have googled a bit in order to do this, but all the info I was finding was a bit obsolete, so use this info if you want, but the main purpose of writting this down is so I can remember it next time (hopefully without being obsolete):

After installing Apache2 from synaptic...

sudo gedit /etc/hosts

Add line...

127.0.0.1	ricardocabello.local

then...

sudo gedit /etc/apache2/sites-available/ricardocabello

with this kind of content...

<VirtualHost *>
	ServerName ricardocabello.local
	DocumentRoot /home/mrdoob/Desktop/www/ricardocabello.com/
</VirtualHost>

save the file, and then...

sudo a2ensite

chose ricardocabello (this will mainly create a link on sites-enabled). And then, to complete the task:

sudo /etc/init.d/apache2 reload

0 comments written so far...


Have your say!

Name:

Website:

Comment:

Some of the projects that I worked on.



Some of the HTML5 and Actionscript experiments I've done.