[ubuntu] apache enable virtual hosts

fisierele de configurare se afla in :

/etc/apache2/

fisierele de configurare a domeniilor sunt in

/etc/apache2/sites-available

iar, apache2 le activeaza pe alea care sunt in directoriu :

/etc/apache2/sites-enabled
husanu@srv1:/etc/apache2/sites-enabled$ ls -l
total 0
lrwxrwxrwx 1 root root 39 2010-01-09 22:45 a.com.conf -> /etc/apache2/sites-available/a.com.conf

si continutul fisierului de configurare a.com.conf

<VirtualHost *:80>
    ServerName a.com
    ServerAdmin webmaster@puk.ro
    DocumentRoot /var/www/a.com
    ErrorLog /var/log/apache2/a.com.log
    CustomLog /var/log/apache2/a.com.access.log combined
</VirtualHost>
<VirtualHost *:80>
    ServerName a.a.com
    ServerAdmin webmaster@puk.ro
    DocumentRoot /var/www/a.a.com
    ErrorLog /var/log/apache2/a.a.com.log
    CustomLog /var/log/apache2/a.a.com-access.log combined
</VirtualHost>
acest fisier de configurare raspunde pt domeniile a.com si a.a.com