I’m trying to port over a website written in CFWheels 1.4 and on Adobe CF 10 to Lucee 5.x… There has been lots of conflicting info out there and it’s not been straight forwards. Such as mod_cfml is now included as default etc… All good when you get your head around it but as of now I’m struggling to get things going. As of now I am on latest Lucee, CfWheels etc…
The Issue:
It seems that when I use an “include” (cfinclude) it is referencing the default Lucee docRoot and cannot find the included file(s) for the context. CFWheels adds a layer of complexity for sure but the issue to me seems around the path and context of the include function and maybe I’m missing something obvious:
given the CFWheels Application file in /var/www/website/Application.cfc
component output="false" {
include "wheels/functions.cfm";
}
It looks like it is trying to find the file in the default DocRoot and fails
/opt/lucee/tomcat/webapps/ROOT
when it should be looking finding the file at /var/www/website/wheels/functions.cfm
Error log:
Page /wheels/functions.cfm [/var/www/website/wheels/functions.cfm] not found
The file does exist and I’m able to output CFML when calling a file not using any "include"s
I’ve tried Apache config with both AJP and HTTP and see the same behaviour
ProxyPassMatch ^/(.+.cf[cm])(/.*)?$ ajp://127.0.0.1:8009/$1$2 secret=SECRET
ProxyPassReverse / ajp://127.0.0.1:8009/
or
proxyPassMatch ^/(.+.cf[cm])(/.*)?$ http://127.0.0.1:8888/$1$2
ProxyPassReverse / http://127.0.0.1:8888/
I can see the context in Lucee admin
I’m using:
Linux Ubuntu 22.04
Apache 2.4.52
Lucee 5.4.3.2
CFWheels 2.4.0
modcfml.conf (as defined in mods-enabled and has a valve in tomcat server.xml)
CFMLHandlers “.cfm .cfc .cfml”
ModCFML_SharedKey {KEY}
LogHeaders false
LogHandlers false
LogAliases false
VDirHeader false
/var/www/website/WEB-INF exists as does
/opt/lucee/tomcat/conf/Catalina/www-website-com-www-website-com-confl15/ROOT.xml
Apache is configured with the following
<IfModule mod_proxy.c>
# proxy via ajp
ProxyPassMatch ^/(.+\.cf[cm])(/.*)?$ ajp://127.0.0.1:8009/$1$2 secret=SECRET
ProxyPassReverse / ajp://127.0.0.1:8009/
# proxy via http 1.1
#ProxyPassMatch ^/(.+\.cf[cm])(/.*)?$ http://127.0.0.1:8888/$1$2
#ProxyPassReverse / http://127.0.0.1:8888/
</IfModule>
<Directory /var/www//website>
Options FollowSymLinks MultiViews
DirectoryIndex index.cfm
AllowOverride None
Require all allow
ProxyAddHeaders on
ProxyPreserveHost On
</Directory>
No log files are modified within the www/website context but the following log files are modified in the opt/lucee folders
opt/lucee/tomcat/lucee-server/context/logs/application.log
/opt/lucee/tomcat/logs/catalina.out
Any help would be greatly appreciated