Hello
Which directory used for web server? "/var/www/html/" or "/srv/" ?
Thanks.
"/var/www/html/" or "/srv/" ?
Re: "/var/www/html/" or "/srv/" ?
Either one should work the same. The default is /var/www/html so it shouldn't need too much to work but if you want to use /srv/, just make sure your SELinux contexts are correct and httpd knows that's where to look
Re: "/var/www/html/" or "/srv/" ?
See https://refspecs.linuxfoundation.org/FH ... hs-3.0.pdf, page 16 section 3.17. /srv : Data for services provided by this system. What I've done in the past is to expose services by linking to the specific directory, for instance /srv/www -> /var/www or /srv/wiki -> /Dokuwiki. The advantage of doing this is that you can move applications according to cluster or space demands whilst retaining a published entry.
Re: "/var/www/html/" or "/srv/" ?
It's always a good practice to use the "/var/www/html" for webpages over other directory because it's already been setup for webpages purpose, if you use srv it's a different purpose. The advantage of using "/var/www/html" is the security hierarchy anything inside the /html only belong to that folder. But if you use other directory you need to do more setup adjustment on the initial setup, it can be done but it will take some time and digging of the files. Hope that helps a bit.