New Railo installs, by default, are set up to integrate with FLEX. This should either be an option during installation, or... it should be an option during installation. I had never used the new railo-...-installer.run program, I really liked it a lot, but I really wish it had asked me if I wanted FLEX integration in the process. It's a small thing, but it's always the smallest things that make the biggest difference. It's okay, I'm still a [Railo] believer.
So, to fix this issue, go to the bottom of /opt/railo/lib/railo-server/context/railo-server.xml (or where ever you have your Railo engine installed)
Change:
To:
Then you cango to your website root directory and run:
That will show all of the 'WEB-INF' directories that you don't need (in your /images, /css, /js, ...) that you should delete with following command:
$ sudo rm -RIf ./images/WEB-INF
$ sudo rm -RIf ./js/WEB-INF
... etc., etc.
Notes on the above: the 'R' = recursive, the 'I' (capital i, not lowercase L) ignores errors, and the 'f'' means 'force' to ignore 'are you sure' confirmation questions.
Then you can go into the Railo SERVER admin and Restart the server there, or recycle Tomcat and that will regenerate the one and only required 'WEB-INF' in the web root directory.
- UPDATE -
It turns out the above was not the only issue, as it was not completely resolved. After a lot more testing I found that I had also incorrectly set up my Tomcat Virtual Hosts. On this Ubuntu Railo-Tomcat server the Tomcat server.xml is located in /opt/railo/tomcat/conf/server.xml. My site's host xml was not set up correctly - missing the attribute 'autoDeploy' in conjunction with having an unwanted 'appBase' attribute. (See the first and second wrong ways below.)
My first WRING way:
<context path="" docbase="">
...
</host>
My Second WRONG way:
<context path="" docbase="website1">
...
</host>
// this actually worked, but we don't need appBase at all for CFM. the reason the first attempt above was screwing things up is that not setting 'autoDeploy' at all defaulted to 'true'. Setting it to false fixed the WEB-INF in the sub-directories, but it's still not right.
Here is the RIGHT way:
<context path="" docbase="/var/www/website1">
...
</host>
That's today's lesson learned.
No comments:
Post a Comment