httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brolin Empey <bro...@brolin.be>
Subject Re: [users@httpd] how to avoid duplicating the document root in vhost conf files?
Date Tue, 06 Oct 2009 21:34:14 GMT
2009/10/6 Jonathan Zuckerman <j.zuckerman@gmail.com>:
> Ah I see... I'm a software engineer too so I appreciate trying to
> encapsulate often-used values but I'd say this might be one of those
> battles it wouldn't kill you to forfeit.

I am a hacker, not an engineer. ;)  In any case, I am not a
professional engineer, so I would not call myself an engineer.

Anyway, did you notice my FIXME about avoiding the duplicated paths is
dated 2009-09-15?  I have already deferred publicly asking about this
issue for over half a month because it is a low priority and I am
probably the only person who cares about it, but I am a perfectionist
sometimes, so I want to avoid the duplication.

> That said, have you tried using relative paths for the error log path
> declarations?

No, I have not.  Since the ${DOCUMENT_ROOT} variable exists, why can I
not use it in my vhost conf file? :(

>  Or (my preferred solution) put them outside the
> document root; why bother putting them in the doc root and then making
> a directory override to disallow outside access to them when the
> simpler solution would be to just put them outside the web root and
> never ever worry about access rules.

I know that is a simpler and probably more logical solution, but I
kept the logs under the doc root for at least 2 reasons:

1. The Web howto about configuring apache2 vhosts on Debian/Ubuntu I
used used this config in its examples.  That howto lacks credibility,
though, because it has errors (singular versus plural nouns) in the
paths to the vhost conf files and does not even prevent world/public
access to the logs!  (epic fail)

2. Because my VPS is hosting multiple vhosts, I thought it was tidier
to keep the logs in the doc root.  I know it does not make much sense
because the logs are not public content, but it was an arbitrary
decision:  I had to keep the logs /somewhere/.  Yes, I suppose
/var/log/ is a better home for apache logs than /var/www/.



I mean this completely politely, but you should trim your quotes to
include only relevant text, not entire messages, including signatures
and footers.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message