Lucee, Apache, PHP - Sanity Check

What mod_cfml does is sets up a VirtualHost in Tomcat, it does this by passing some headers across with the request which allow it to distinguish your virtual hosts in Apache. So if you only have one domain / site on the server it is not necessary to use mod_cfml. If you want to do virtual hosts and don’t want to setup virtual host configuration twice (once on apache and again in Tomcat server.xml), then mod_cfml saves you some time.

mod_cfml is not a reverse proxy, you would set that up with Apache’s directives provided by the mod_proxy module. When you run the lucee installer it will set this up globally with the apache directives so that all sites can be served by lucee.

CommandBox is great, and it could be used as a backend server for your reverse proxy setup as well, but you would probably have to spin up a new server (jvm process) for each site and that might take more resources than just a single lucee instance with mod_cfml. You can’t use mod_cfml with commandbox because it doesn’t run on Tomcat, and mod_cfml requires a tomcat valve to be setup.

I think the reason you won’t find many guides on lucee + php is that if you just follow a setup guide for lucee on Apache and then follow a guide for php on Apache it should just work in most cases.

Hope that helps clarify.

Pete Freitag
https://foundeo.com/

2 Likes