[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: FHS and /var/www

Le Sun, Jul 20, 2008 at 01:43:12AM +0200, Carl Fürstenberg a écrit :
> FHS 2.3 specifies in
> http://www.pathname.com/fhs/pub/fhs-2.3.html#SRVDATAFORSERVICESPROVIDEDBYSYSTEM
> to use /srv for "Data for services provided by this system", for
> example /srv/www for web root.
> In the policy, the section
> 9.1.1(http://www.debian.org/doc/debian-policy/ch-opersys.html#s9.1.1)
> specifies that FHS 2.3 is mandatory, except for some exception, and
> the use of /var/www isn't included in that list.
> Should we force all httpd:s to use /srv/www instead of /var/www, or
> should an exception to the policy be added? Per
> http://wiki.debian.org/Apache2LennyGoals it states that apache2 has
> support for /srv/www, but it's still defaulting to /var/www.

Hi Carl,

I think that there is an confusion between where the web servers that
are packaged for Debian should look for the sites to serve, and where
the sites packaged for Debian should install their files.

Be it /var/www or /srv/www, nothing guarantees that a package shipping a
file in these directories will not conflict with local data, similarly
to /usr/local: the local administrator may have already placed a file
with as similar name, which would make the package uninstallable. In
contrary, the local administrator is not supposed to add anything that
does not come from a package in /usr/share nor /usr/lib.

For this reason, packages containing websites should use paths such as
/usr/lib/cgi-bin and /usr/share/package for their files.

Of course, this complexifies the task for the packager, as the http
daemons will not look by default in /usr/share/package. Definitely, some
code factorisation for registering the files and reload the
configuration would be most welcome. Maybe it could be some kind of goal
for Lenny+1?

Have a nice day,

Charles Plessy
Debian-Med packaging team,
Tsurumi, Kanagawa, Japan

Reply to: