Item615: Apache Config Generator generates faulty configs
Priority: Normal
Current State: No Action Required
Released In:
Target Release: n/a
Applies To: Web Site
Component:
Branches:
Affected component “
Apache Config Generator”
Changing the path to the root directory does not generate a correct config file i.e. if “/var/www/foswiki” is changed to “/var/www/test” the line “ScriptAlias /foswiki/bin /var/www/test/bin” is generated, this should surly be “ScriptAlias /test/bin /var/www/test/bin”. Other lines follow the same form and are also therefore wrong.
Effectively this means only one foswiki per machine and it must be referenced by the path “/***/***/foswiki”; most people will do this so the bug will probably only hit the more adventurous.
I don't see anything wrong with this. We have two fields:
-
Enter the full file path to your foswiki root directory
(e.g. /var/www/foswiki)
-
Enter the url path which foswiki is accessed
(e.g. /foswiki)
And unless we know the
DocumentRoot
setting, there is no way to relate these fields (and even if we knew, I'm for having them independent from each other)
--
GilmarSantosJr - 11 Apr 2009
Changing the physical path name should NOT automatically change the logical path.
I personally never have a 1:1 match between then in anything I have installed.
The whole idea of the alias is that it is an alias. It is a name projected on to something else.
The default /var/www prefix I added to the
ApacheConfigGenerator when I created the first version comes from the RedHat family.
The /var/www directory is the base directory for all the Apache data but it is NOT the document root. The document root is /var/www/html. People from the debian world get confused by this sometimes because they have as far as I know /vaw/www as document root. Ie a file placed in /var/www appears available in the browser. For the same reason /var/www is not a good prefix for debian. Not easy to resolve. And Debian is not more correct than RedHat. Nothing is correct in this question. They are just different.
The message is that the foswiki directory should not - unless you have to on a shared host - be in the document root. I chose the /var/www location for RedHat/Fedora/Centos because this directory is owned by the Apache user so it made access rights more simple for the beginner and you then have everything gathered in one place. But you could also place the foswiki in /user/local/foswiki104 and then make an alias
ScriptAlias /legocollectors/scripts /user/local/foswiki104/bin
There is no requirement to have the two match at all.
The original ApacheConfigGenerator I made hardcoded the logical path to /foswiki (or actually the original was the name of "the other project"). Things have evolved since and will continue to evolve. And the logical and physical paths are now two fields.
So no action needed here
--
KennethLavrsen - 13 Apr 2009