I started apache today and to my amazement I found it displayed the (s)thttpd default, which turned out to be /var/www/localhost/htdocs/index.html and owned by the www-servers/thttpd ebuild. With webapp-config based ebuilds installed, it's probably not a good idea to write to that directory directly, possibly overwriting something "carefully" installed through webapp-config. Even on it webapp-config based sites, it could overwrite or otherwise break whatever is run from the HTTP root directory.
(In reply to comment #0) > I started apache today and to my amazement I found it displayed the > (s)thttpd default, which turned out to be > /var/www/localhost/htdocs/index.html and owned by the www-servers/thttpd > ebuild. > > With webapp-config based ebuilds installed, it's probably not a good idea to > write to that directory directly, possibly overwriting something "carefully" > installed through webapp-config. > > Even on it webapp-config based sites, it could overwrite or otherwise break > whatever is run from the HTTP root directory. Maybe we should take this opportunity to establish a standard. Here's what's going on with our other www-servers: 1) thttpd installs the following under /var/www: /var/www/localhost/htdocs/cgi-bin/ssi /var/www/localhost/htdocs/cgi-bin/phf /var/www/localhost/htdocs/cgi-bin/redirect /var/www/localhost/htdocs/cgi-bin/printenv /var/www/localhost/htdocs/index.html 2) monkeyd installs: /var/www/localhost/htdocs/404.html /var/www/localhost/htdocs/imgs/monkey_logo.png /var/www/localhost/htdocs/index-monkey.html /var/www/localhost/htdocs/favicon.ico 3) cherokee installs: /var/www/localhost/htdocs/images/default-bg.png /var/www/localhost/htdocs/images/powered_by_cherokee.png /var/www/localhost/htdocs/images/cherokee-logo.png /var/www/localhost/htdocs/images/favicon.ico /var/www/localhost/htdocs /var/www/localhost/htdocs/index.html 4) lightthpd installs: /var/www/localhost/htdocs <- just the directory 5) apache doesn't install anything. A subtle point about cherokee and lighttpd, they actually "install" the directory so that /var/www/localhost/htdocs is part of the list of files belonging to the package. My recommendation is that 1) no www-server install anything under /var/www, 2) the branding that comes with monkeyd, cherokee etc, be moved to /usr/share/doc/${P}/htdocs-default I take care of monkeyd, cherokee and thttpd (in fact, I forked the code for the latter since its been abandoned for six years, yet users protested dropping it). wired and hwoarang take care of lighttpd. Opinions? We can then adjust our packages accordingly
1) Do we actually need /anything/ in the docroot for a specific server to work? Wouldn't it simply return a 404 (when a required file is absent) or perhaps a 5NN (when the presence of a file is considered a required part of the configuration)? 2) If the files are required to be installed there, is webapp-config capable of handling the stuff you would want to have in the docroot? 3) If not, should we fix webapp-config to handle that?
(In reply to comment #2) > 1) Do we actually need /anything/ in the docroot for a specific server to > work? I tested and we do not. All you need is a directory /var/www/localhost/htdocs but it can (and should) be empty. So I'm taking the approach of lightthpd. I've applied the change to thttpd-2.26.4-r1. Take a look and let me know what you think and I'll do the same for monkeyd and cherokee.
Okay all of the www-servers I take care of now install nothing into /var/www/localhost/htdocs. I moved their "logo" pages to /usr/share/doc/${PF}/htdocs.dist. I think this issue is done. Reopen if there's anything else.