Ubuntu 9.10 e Apache: Virtual Host

Ho seguito questa guida e non ho avuto problemi:

http://www.debuntu.org/2006/02/22/7-virtual-hosting-using-apache-2

In pratica:

- In /home/nicola/Pubblici/www/prova.com ho creato un file index.html

- Nella directory /etc/apaches/site-avaiable ho creato un file dal nome prova.com.conf così fatto:

<VirtualHost *:80>
ServerAdmin webmaster@localhost
#We want to be able to access the web site using www.dev.example.com or dev.example.com
ServerAlias www.prova.com
DocumentRoot /home/nicola/Pubblici/www/prova.com
#if using awstats
ScriptAlias /awstats/ /usr/lib/cgi-bin/
#we want specific log file for this server
CustomLog /var/log/apache2/prova.com-access.log combined
</VirtualHost>

- ho aggiunto nel file /etc/hosts  la voce

127.0.0.1     www.prova.com

- ho riavviato apache

- ho impostato i permessi di lettura alla cartella www:

sudo chmod -R a=rx /home/nicola/Pubblici/www

Leave a Reply

Your email address will not be published.

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>