0

Why is in standard apache2.conf only the container directive <Directory /var/www/> instead of the docroot <Directory /var/www/html>?

I have the following release:

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 16.04.5 LTS
Release:    16.04
Codename:   xenial

And I am using apache 2.4.

John Goofy
  • 129
  • 5
  • It might depend on your linux distribution. For example, the default value for DocumentRoot is /usr/local/apache/htdocs, https://httpd.apache.org/docs/2.4/mod/core.html#documentroot . Could you provide some additional information about your linux distribution? – Mike Marseglia Dec 10 '18 at 13:11
  • Yes, of course. I can provide some additional information. Please view my edit. – John Goofy Dec 10 '18 at 13:15
  • There's a pretty good explanation here: https://serverfault.com/questions/588380/what-is-the-difference-between-documentroot-and-directory-in-apache2-for-mac-os Main thing from it is that Directory lets you specify config rules that pertain to that directory while docroot just specifies where to pull files from when visiting that vhost. It doesn't matter if it's in apache2.conf or in a site config file. – SteamerJ Dec 10 '18 at 16:29

0 Answers0