OpenLaszlo and symlinks

Written on January 20th 2010, 15:01 by sYnie

I develop OpenLaszlo apps on different OL versions. But as I usually need the code to be the same, I use symlinks (symbolic links / soft links) to my apps within the tomcat server of OpenLaszlo. This leads to problems with non-lzx-files. Tomcat just doesn’t recognize other files.
There are some Sites out there, that point out a solution to this. But every time I install a new version of OpenLaszlo, I search for a minimum of 30 minutes until I found it. I think I’ve already bookmarked it, but it’s lost in thousands of OL bookmarks.
However, I thought to blog this solution. So I won’t need to search anymore in the future ;-)

So if you’re facing problems with symlinks using OpenLaszlo, just edit this file:
/path/to/openlaszlo/Server/tomcat-5.0.24/conf/LPS/localhost/lps.xml

<?xml version='1.0' encoding='utf-8'?>
<Context docBase="../../lps-x.x.x" path="/lps-x.x.x">
...
</Context>

And apply the following changes:

<?xml version='1.0' encoding='utf-8'?>
<Context docBase="../../lps-x.x.x" path="/lps-x.x.x" allowLinking="true">
...
</Context>

That’s it.
Thanks again to the OL Forums (source)

  1. No comments yet.
  1. No trackbacks yet.