1/ éditer /etc/hosts, ajouter :
127.0.0.1 nomsite.local
2/ dans /etc/apache2/sites-available , rajouter un nomsite.local.conf avec ces lignes :
<VirtualHost *:80>
ServerName nomsite.local
DocumentRoot /home/chemin_vers/lesite/www # chemin vers le projet
<Directory />
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.lesite.log
CustomLog ${APACHE_LOG_DIR}/access.lesite.log combined
</VirtualHost>
3/ Il faut la même chose dans le dossier /etc/apache2/sites-enabled, une commande existe pour ça :
sudo a2ensite monsite1.conf
4/ recharger apache2 :
sudo /etc/init.d/apache2 reload
Hi, this is a comment.
To get started with moderating, editing, and deleting comments, please visit the Comments screen in the dashboard.
Commenter avatars come from Gravatar.