Mark
asked on
allowLinking - making Unix symlinks work with tomcat
========================== ==
I have installed tomcat 6.0.14 on my Linux 2.4.29 kernel. The tomcat RELEASNOTES contain the following:
Symlinking static resources:
========================== ==
By default, Unix symlinks will not work when used in a web application to link
resources located outside the web application root directory.
This behavior is optional, and the "allowLinking" flag may be used to disable
the check.
I am using symlinks for various aspects of the tomcat installation. I haven't run into a problem so far, but I'd rather be safe than sorry. Where do I find this elusive "allowLinking" flag? The RELEASE-NOTES.txt simply says it exists, but apparently assumes the reader knows where. I see references to it in ./webapps/docs/config/prin ter/contex t.html and ./webapps/docs/config/cont ext.html, but these just appear to be documentation, not configuration.
Where, and how do I set it?
I have installed tomcat 6.0.14 on my Linux 2.4.29 kernel. The tomcat RELEASNOTES contain the following:
Symlinking static resources:
==========================
By default, Unix symlinks will not work when used in a web application to link
resources located outside the web application root directory.
This behavior is optional, and the "allowLinking" flag may be used to disable
the check.
I am using symlinks for various aspects of the tomcat installation. I haven't run into a problem so far, but I'd rather be safe than sorry. Where do I find this elusive "allowLinking" flag? The RELEASE-NOTES.txt simply says it exists, but apparently assumes the reader knows where. I see references to it in ./webapps/docs/config/prin
Where, and how do I set it?
ASKER
Thanks! As my Author line shows, I'm a beginner in this area (you helped me on a previous question). Your link indicates that it is an atribute I can put in context.html; and if I put it in my $CATALINA_HOME/conf/contex t.xml it will apply to all webapps. That's what I want. Unfortunately, I see no examples of how to specity this attribute (I'm new at xml as well). Below is my actual as-shipped .../conf/context.xml. I've attempted to put allowLinking in there. Please correct:
<!-- The contents of this file will be loaded for each web application -->
<Context>
<!-- Default set of monitored resources -->
<WatchedResource>WEB-INF/w eb.xml</Wa tchedResou rce>
<allowLinking>true</allowL inking>
</Context>
<!-- The contents of this file will be loaded for each web application -->
<Context>
<!-- Default set of monitored resources -->
<WatchedResource>WEB-INF/w
<allowLinking>true</allowL
</Context>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
ah ha! Got it. OK, I've put it in my .../conf/context.xml. I don't know if I can test it or not. I'll just assume it works until something tells me otherwise. Thanks!
http://tomcat.apache.org/tomcat-5.5-doc/config/context.html