Contenu | Rechercher | Menus

Annonce

Si vous avez des soucis pour rester connecté, déconnectez-vous puis reconnectez-vous depuis ce lien en cochant la case
Me connecter automatiquement lors de mes prochaines visites.

À propos de l'équipe du forum.

#1 Le 01/12/2006, à 15:55

zubaran

Prob de multidomaine

Bonjour,

J'ai voulu suivre le tutorial :

http://planet.ubuntu-fr.org/index.php?q=apache%20virtualhost

Pour installer plusieurs domaines mais n'ayant pas trop compris ce qu'il fallait faire j'ai supprimé toutes les lignes présentes dans /etc/apache2/sites-available/default pour y mettre les lignes suivantes :

@@ NameVirtualHost *:80

<VirtualHost *:80>
dFebmaster@abandonware-paradise.fr
ServerName abandonware-paradise.fr.tld
DocumentRoot /var/www/abandonware-paradise/
ErrorLog /home/httpd/vhosts/abandonware-paradise.fr.tld/logs/error.log
LogLevel warn
CustomLog /home/httpd/vhosts/abandonware-paradise.fr.tld/logs/access.log combined
ServerSignature On
</VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@abandonware-paradise.fr
ServerName abandonware-paradise.net.tld
DocumentRoot /var/www/abandonware-paradise/
ErrorLog /home/httpd/vhosts/abandonware-paradise.net.tld/logs/error.log
LogLevel warn
CustomLog /home/httpd/vhosts/abandonware-paradise.net.tld/logs/access.log combined
ServerSignature On
</VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@abandonware-paradise.fr
ServerName abandonware-paradise.org.tld
DocumentRoot /var/www/abandonware-paradise/
ErrorLog /home/httpd/vhosts/abandonware-paradise.org.tld/logs/error.log
LogLevel warn
CustomLog /home/httpd/vhosts/abandonware-paradise.org.tld/logs/access.log combined
ServerSignature On
</VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@abandonware-paradise.fr
ServerName abandonware-paradise.eu.tld
DocumentRoot /var/www/abandonware-paradise/
ErrorLog /home/httpd/vhosts/abandonware-paradise.eu.tld/logs/error.log
LogLevel warn
CustomLog /home/httpd/vhosts/abandonware-paradise.eu.tld/logs/access.log combined
ServerSignature On
</VirtualHost>

@@

Lorsque je redémarre apache il me dit qu'il ne connait pas les commandes @@, et biensur comme j'ai viré les autres lignes j'arrive plus du tout à me connecter aux pages webs sur mon serveur.

Quelqu'un pourrait-il me tirer de ce pétrin et si possible m'indiquer comment gérer des multidomaines.

Merci

#2 Le 01/12/2006, à 19:16

NooP

Re : Prob de multidomaine

Salut,

1 : Le default d'origine

NameVirtualHost *
<VirtualHost *>
        ServerAdmin webmaster@localhost

        DocumentRoot /var/www/html
        <Directory />
                Options FollowSymLinks
                AllowOverride None
        </Directory>
        <Directory /var/www/html/>
                Options Indexes FollowSymLinks MultiViews
                AllowOverride None
                Order allow,deny
                allow from all
        </Directory>

        ScriptAlias /cgi-bin/ /var/www/cgi-bin/
        <Directory "/var/www/cgi-bin">
                AllowOverride None
                Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
                Order allow,deny
                Allow from all
        </Directory>

        ErrorLog /var/log/apache2/error.log

        # Possible values include: debug, info, notice, warn, error, crit,
        # alert, emerg.
        LogLevel warn

        CustomLog /var/log/apache2/access.log combined
        ServerSignature Off

</VirtualHost>

2: Un site (étrange) ou tu trouveras toute la doc ...

http://httpd.apache.org/docs/2.2/vhosts/

3: Au lieu de modifier ton default,

a2dissite default

tu en fais un copie sous un autre nom (pourquoi pas abandonware)
Tu fais les modifs que tu veux dedans

a2ensite abandonware
/etc/init.d/apache2 restart

Dernière modification par NooP (Le 01/12/2006, à 19:42)


Votez Macron, vous l'aurez dans le fion !

Hors ligne

#3 Le 02/12/2006, à 15:07

zubaran

Re : Prob de multidomaine

Merci bien wink