Have got a working build of Lucee 5 PREVIEW (“Velvet”) put together from the JARs distro for the Lucee 5 Docker containers. Thought it might be worth highlighting how this is constructed for others who might be trying to hand craft “Velvet” builds.
Things will likely change for the better as we move toward a GA release but for now there are four parts to the build:
- core lucee core JAR
- org.apache.felix.framework-4.2.1.jar; OSGi framework
- lucee dependencies ZIP
- lucee extensions (cobbled together from Express build)
Assuming a standard linux based install similar to the official installers for Tomcat 8 you might assemble things as follows…
Lucee core is super small, and easily available as an automated build called JAR. Unfortunately, if you are used to getting the old JARs distro this is not it! You will need to pull down Lucee core and place it in your Tomcat install like so:
cp /tmp/lucee.jar /usr/local/tomcat/lucee/lucee.jar
The Felix framework is critical to get things working, but its completely missing from the list of artefacts Lucee provides at the moment. Get hold of Felix by hook or by crook and put him next to lucee.jar like so:
cp /tmp/lucee.jar /usr/local/tomcat/lucee/org.apache.felix.framework-4.2.1.jar
The Dependencies comes as a ZIP of all the needed JAR libs. You need to unpack them into a new folder called
unzip /tmp/lucee-jars.zip -d /opt/lucee/server/lucee-server/bundles
Last but not least you need the Extensions. Seeing as everything in Lucee 5 is going to be extensions, these are pretty critical. Unfortunately, there is currently no automated distribution of the latest extensions although thankfully they are not particularly volatile. You can snarf them from the Express install; the files with the
The Extensions must be copied into the
./deploy folder like so:
cp extensions/ /opt/lucee/server/lucee-server/context/deploy/
When Lucee 5 starts up it scans the
deploy directory, installs any extension it finds, and deletes the extension packages from the folder.
If you want to have a play you can always spin up the Vagrantfile workbench we have for the Lucee Dockerfiles project.
The Lucee 5 Dockerfile, related assets and configs are all available on Github at:
Full Lucee 5.0 Dockerfile available below so you don’t have to go hunting:
FROM tomcat:8-jre8 MAINTAINER Geoff Bowers <email@example.com> ENV LUCEE_JARS_URL http://daemon-provisioning-resources.s3.amazonaws.com/lucee/5.0/lucee-184.108.40.206-20151023.035428-4.jar ENV LUCEE_DEPS_URL http://daemon-provisioning-resources.s3.amazonaws.com/lucee/5.0/lucee-220.127.116.11-BETA-dependencies.zip # Download core JAR, and delete it in one step to avoid committing the installer in a FS layer RUN wget -nv $LUCEE_JARS_URL -O /root/lucee.jar && \ mkdir -p /usr/local/tomcat/lucee && \ cp /root/lucee.jar /usr/local/tomcat/lucee/lucee.jar && \ rm -rf /root/lucee.jar # COPY over random missing dependencies; OSGi framework COPY org.apache.felix.framework-4.2.1.jar /usr/local/tomcat/lucee/ # Download lucee dependencies RUN wget -nv $LUCEE_DEPS_URL -O /root/lucee-jars.zip && \ mkdir -p /opt/lucee/server/lucee-server/bundles && \ unzip /root/lucee-jars.zip -d /opt/lucee/server/lucee-server/bundles && \ rm -rf /root/lucee-jars.zip # COPY over Lucee extensions RUN mkdir -p /opt/lucee/server/lucee-server/context/deploy /opt/lucee/web COPY extensions/ /opt/lucee/server/lucee-server/context/deploy/ # Delete the default Tomcat webapps so they aren't deployed at startup RUN rm -rf /usr/local/tomcat/webapps/* # Set Tomcat config to load Lucee COPY catalina.properties server.xml web.xml /usr/local/tomcat/conf/ # Custom setenv.sh to load Lucee COPY setenv.sh /usr/local/tomcat/bin/ RUN chmod a+x /usr/local/tomcat/bin/setenv.sh # Create Lucee configs COPY lucee-server.xml /opt/lucee/server/lucee-server/context/lucee-server.xml COPY lucee-web.xml.cfm /opt/lucee/web/lucee-web.xml.cfm # Create webroot with a default index.cfm RUN mkdir -p /var/www COPY index.cfm /var/www/ # Remove test page when used as base image ONBUILD RUN rm -rf /var/www/*