eb8bcdc Initial commit.
- Authored by Peter Boughton at Fri 22 May 2020, 15:02
lucee.mod (new) | 23 +++++++
lucee/etc/lucee-global-webapp-common.xml (new) | 14 ++++
lucee/etc/lucee-rewrite-rules.xml (new) | 35 ++++++++++
lucee/etc/lucee-servlets.xml (new) | 68 ++++++++++++++++++++
lucee/etc/lucee-webapp-common.xml (new) | 8 +++
lucee/lib/lucee_jar_goes_here (new) | 0
6 files changed, 148 insertions(+)
diff --git a/lucee.mod b/lucee.mod
new file mode 100644
index 0000000..4c44919
--- /dev/null
+++ b/lucee.mod (view file)
@@ -0,0 +1,23 @@
+#
+# Lucee Module
+#
+
+[description]
+Enables Lucee CFML engine.
+
+[depend]
+http
+jsp
+rewrite
+
+[lib]
+modules/lucee/lib/**.jar
+
+[ini]
+modules/lucee/etc/lucee-rewrite-rules.xml
+modules/lucee/etc/lucee-global-webapp-common.xml
+
+[files]
+basehome:modules/lucee/lucee-server/
+basehome:modules/lucee/webapps/
+basehome:modules/lucee/webinfs/
\ No newline at end of file
diff --git a/lucee/etc/lucee-global-webapp-common.xml b/lucee/etc/lucee-global-webapp-common.xml
new file mode 100644
index 0000000..448d440
--- /dev/null
+++ b/lucee/etc/lucee-global-webapp-common.xml (view file)
@@ -0,0 +1,14 @@
+<?xml version="1.0"?>
+<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "http://www.eclipse.org/jetty/configure_9_3.dtd">
+
+<Configure id="Server" class="org.eclipse.jetty.server.Server">
+ <Ref refid="DeploymentManager">
+ <Call name="addLifeCycleBinding">
+ <Arg>
+ <New class="org.eclipse.jetty.deploy.bindings.GlobalWebappConfigBinding" >
+ <Set name="jettyXml"><Property name="jetty.base"/>/modules/lucee/etc/lucee-webapp-common.xml</Set>
+ </New>
+ </Arg>
+ </Call>
+ </Ref>
+</Configure>
\ No newline at end of file
diff --git a/lucee/etc/lucee-rewrite-rules.xml b/lucee/etc/lucee-rewrite-rules.xml
new file mode 100644
index 0000000..22d2172
--- /dev/null
+++ b/lucee/etc/lucee-rewrite-rules.xml (view file)
@@ -0,0 +1,35 @@
+<?xml version="1.0"?>
+<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "http://www.eclipse.org/jetty/configure_9_0.dtd">
+<Configure id="Server" class="org.eclipse.jetty.server.Server">
+
+ <Call name="insertHandler">
+ <Arg>
+ <New class="org.eclipse.jetty.rewrite.handler.RewriteHandler">
+ <Set name="originalPathAttribute">requestedPath</Set>
+ <Set name="rewriteRequestURI">true</Set>
+ <Set name="rules">
+ <Array type="org.eclipse.jetty.rewrite.handler.Rule">
+ <Item>
+ <New class="org.eclipse.jetty.rewrite.handler.VirtualHostRuleContainer">
+ <!--
+ Rewrite {anyscript}.cfm/path_info URLs to {anyscript}.cfm so it is
+ matched by Lucee's servlet mapping. (Lucee populates cgi.path_info
+ from Jetty's requestedPath, which holds the original Request URI.)
+ -->
+ <Call name="addRule">
+ <Arg>
+ <New class="org.eclipse.jetty.rewrite.handler.RewriteRegexRule">
+ <Set name="regex">(.*?\.(?:cfm|lucee))/.*</Set>
+ <Set name="replacement">$1</Set>
+ </New>
+ </Arg>
+ </Call>
+ </New>
+ </Item>
+ </Array>
+ </Set>
+ </New>
+ </Arg>
+ </Call>
+
+</Configure>
\ No newline at end of file
diff --git a/lucee/etc/lucee-servlets.xml b/lucee/etc/lucee-servlets.xml
new file mode 100644
index 0000000..957c897
--- /dev/null
+++ b/lucee/etc/lucee-servlets.xml (view file)
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app
+ xmlns="http://xmlns.jcp.org/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
+ metadata-complete="false"
+ version="3.1"
+ >
+
+ <servlet>
+ <servlet-name>CFMLServlet</servlet-name>
+ <servlet-class>lucee.loader.servlet.CFMLServlet</servlet-class>
+ <init-param>
+ <param-name>lucee-server-directory</param-name>
+ <param-value>.</param-value>
+ </init-param>
+ <init-param>
+ <param-name>lucee-web-directory</param-name>
+ <param-value>./webinfs/{web-context-label}/</param-value>
+ </init-param>
+ <load-on-startup>1</load-on-startup>
+ </servlet>
+
+ <servlet>
+ <servlet-name>LuceeServlet</servlet-name>
+ <servlet-class>lucee.loader.servlet.LuceeServlet</servlet-class>
+ <init-param>
+ <param-name>lucee-server-directory</param-name>
+ <param-value>.</param-value>
+ </init-param>
+ <init-param>
+ <param-name>lucee-web-directory</param-name>
+ <param-value>./webinfs/{web-context-label}/</param-value>
+ </init-param>
+ <load-on-startup>2</load-on-startup>
+ </servlet>
+
+ <servlet>
+ <servlet-name>RESTServlet</servlet-name>
+ <servlet-class>lucee.loader.servlet.RestServlet</servlet-class>
+ <load-on-startup>3</load-on-startup>
+ </servlet>
+
+
+ <servlet-mapping>
+ <servlet-name>CFMLServlet</servlet-name>
+ <url-pattern>*.cfc</url-pattern>
+ <url-pattern>*.cfm</url-pattern>
+ </servlet-mapping>
+
+ <servlet-mapping>
+ <servlet-name>LuceeServlet</servlet-name>
+ <url-pattern>*.lucee</url-pattern>
+ </servlet-mapping>
+
+ <servlet-mapping>
+ <servlet-name>RESTServlet</servlet-name>
+ <url-pattern>/rest/*</url-pattern>
+ </servlet-mapping>
+
+
+ <welcome-file-list>
+ <welcome-file>index.cfm</welcome-file>
+ <welcome-file>index.lucee</welcome-file>
+ </welcome-file-list>
+
+
+</web-app>
\ No newline at end of file
diff --git a/lucee/etc/lucee-webapp-common.xml b/lucee/etc/lucee-webapp-common.xml
new file mode 100644
index 0000000..8509852
--- /dev/null
+++ b/lucee/etc/lucee-webapp-common.xml (view file)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "http://www.eclipse.org/jetty/configure_9_3.dtd">
+
+<Configure class="org.eclipse.jetty.webapp.WebAppContext">
+
+ <Set name="overrideDescriptor"><Property name="jetty.base"/>/modules/lucee/etc/lucee-servlets.xml</Set>
+
+</Configure>
\ No newline at end of file
diff --git a/lucee/lib/lucee_jar_goes_here b/lucee/lib/lucee_jar_goes_here
new file mode 100644
index 0000000..e69de29