I just set up the apache2/mysql server to play around with. But I found the something different than what I saw before. The root directory is pointed to /var/www/html/. I checked the /etc/apache2/apache2.conf file ,and says
Options Indexes FollowSymLinks
AllowOverride None
Require all granted
This says the root directory points to /var/www/. Is this a bug ? And I also want to know why they made /var/www/html instead of /var/www/.
Answer
Usually the default configuration (eg. /var/www/html) is defined in /etc/apache2/sites-enabled and is overriding what's in your apache2.conf. This is normal behaviour, and it's common practice to add your vhost config as separate files in /etc/apache2/sites-available then symlink the enabled ones to /etc/apache2/sites-enabled.
If you want to edit the default config edit /etc/apache2/sites-available/000-default.conf.
No comments:
Post a Comment