Compare commits
No commits in common. 'i8c-beta-stream-10.6' and 'c9' have entirely different histories.
i8c-beta-s
...
c9
@ -0,0 +1 @@
|
|||||||
|
SOURCES/tomcat-9.0.50.redhat-00006-src.zip
|
@ -0,0 +1 @@
|
|||||||
|
d3342fad0113532635b6d2ec733e189abeadaf0d SOURCES/tomcat-9.0.50.redhat-00006-src.zip
|
@ -0,0 +1,208 @@
|
|||||||
|
diff -up ./build.xml.orig ./build.xml
|
||||||
|
--- ./build.xml.orig 2021-12-09 13:29:38.000000000 -0500
|
||||||
|
+++ ./build.xml 2022-03-04 08:56:31.987572758 -0500
|
||||||
|
@@ -1032,7 +1032,7 @@
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.annotations-api"
|
||||||
|
manifest="${tomcat.manifests}/annotations-api.jar.manifest"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Servlet Implementation JAR File -->
|
||||||
|
<jarIt jarfile="${servlet-api.jar}"
|
||||||
|
@@ -1041,41 +1041,41 @@
|
||||||
|
manifest="${tomcat.manifests}/servlet-api.jar.manifest"
|
||||||
|
notice="${tomcat.manifests}/servlet-api.jar.notice"
|
||||||
|
license="${tomcat.manifests}/servlet-api.jar.license"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- EL Implementation JAR File -->
|
||||||
|
<jarIt jarfile="${el-api.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.el-api"
|
||||||
|
manifest="${tomcat.manifests}/el-api.jar.manifest"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- JSP Implementation JAR File -->
|
||||||
|
<jarIt jarfile="${jsp-api.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.jsp-api"
|
||||||
|
manifest="${tomcat.manifests}/jsp-api.jar.manifest"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- WebSocket API JAR File -->
|
||||||
|
<jarIt jarfile="${websocket-api.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.websocket-api"
|
||||||
|
manifest="${tomcat.manifests}/websocket-api.jar.manifest"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- JASPIC API JAR File -->
|
||||||
|
<jarIt jarfile="${jaspic-api.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.jaspic-api"
|
||||||
|
manifest="${tomcat.manifests}/jaspic-api.jar.manifest"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Tomcat-juli JAR File -->
|
||||||
|
<jarIt jarfile="${tomcat-juli.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.tomcat-juli"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Bootstrap JAR File -->
|
||||||
|
<jarIt jarfile="${bootstrap.jar}"
|
||||||
|
@@ -1087,61 +1087,61 @@
|
||||||
|
<jarIt jarfile="${tomcat-util.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.tomcat-util"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Tomcat API JAR File -->
|
||||||
|
<jarIt jarfile="${tomcat-api.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.tomcat-api"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Tomcat Util Scan JAR File -->
|
||||||
|
<jarIt jarfile="${tomcat-util-scan.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.tomcat-util-scan"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<jarIt jarfile="${tomcat-jni.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.tomcat-jni"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Protocol handlers - Coyote -->
|
||||||
|
<jarIt jarfile="${tomcat-coyote.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.tomcat-coyote"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- WebSocket implementation JAR File -->
|
||||||
|
<jarIt jarfile="${tomcat-websocket.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.tomcat-websocket"
|
||||||
|
meta-inf="${tomcat.manifests}/tomcat-websocket.jar"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Catalina GroupCom/Tribes JAR File -->
|
||||||
|
<jarIt jarfile="${catalina-tribes.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.catalina-tribes"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Catalina Main JAR File -->
|
||||||
|
<jarIt jarfile="${catalina.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.catalina"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Catalina Cluster/HA JAR File -->
|
||||||
|
<jarIt jarfile="${catalina-ha.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.catalina-ha"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Server-Side Includes (SSI) -->
|
||||||
|
<jarIt jarfile="${catalina-ssi.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.catalina-ssi"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Catalina Ant Tasks JAR File -->
|
||||||
|
<jarIt jarfile="${catalina-ant.jar}"
|
||||||
|
@@ -1152,27 +1152,27 @@
|
||||||
|
<jarIt jarfile="${catalina-storeconfig.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.catalina-storeconfig"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Jasper EL Implementation JAR File -->
|
||||||
|
<jarIt jarfile="${jasper-el.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.jasper-el"
|
||||||
|
meta-inf="${tomcat.manifests}/jasper-el.jar"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Jasper Implementation JAR File -->
|
||||||
|
<jarIt jarfile="${jasper.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.jasper"
|
||||||
|
meta-inf="${tomcat.manifests}/jasper.jar"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- Re-packaged Apache Commons DBCP 2-->
|
||||||
|
<jarIt jarfile="${tomcat-dbcp.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.tomcat-dbcp"
|
||||||
|
- addOSGi="true" />
|
||||||
|
+ addOSGi="false" />
|
||||||
|
|
||||||
|
<!-- i18n JARs -->
|
||||||
|
<jar jarfile="${tomcat.build}/lib/tomcat-i18n-cs.jar"
|
||||||
|
@@ -1635,7 +1635,7 @@
|
||||||
|
filesId="files.tomcat-embed-core"
|
||||||
|
notice="${tomcat.manifests}/servlet-api.jar.notice"
|
||||||
|
license="${tomcat.manifests}/servlet-api.jar.license"
|
||||||
|
- addOSGi="true"
|
||||||
|
+ addOSGi="false"
|
||||||
|
addGraal="true"
|
||||||
|
graalPrefix="org.apache.tomcat.embed/tomcat-embed-core"
|
||||||
|
graalFiles="res/graal/tomcat-embed-core/native-image"
|
||||||
|
@@ -1643,7 +1643,7 @@
|
||||||
|
<jarIt jarfile="${tomcat-embed-el.jar}"
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.tomcat-embed-el"
|
||||||
|
- addOSGi="true"
|
||||||
|
+ addOSGi="false"
|
||||||
|
addGraal="true"
|
||||||
|
graalPrefix="org.apache.tomcat.embed/tomcat-embed-el"
|
||||||
|
graalFiles="res/graal/tomcat-embed-el/native-image"
|
||||||
|
@@ -1652,7 +1652,7 @@
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.tomcat-embed-jasper"
|
||||||
|
meta-inf="${tomcat.manifests}/jasper.jar"
|
||||||
|
- addOSGi="true"
|
||||||
|
+ addOSGi="false"
|
||||||
|
addGraal="true"
|
||||||
|
graalPrefix="org.apache.tomcat.embed/tomcat-embed-jasper"
|
||||||
|
graalFiles="res/graal/tomcat-embed-jasper/native-image"
|
||||||
|
@@ -1661,7 +1661,7 @@
|
||||||
|
filesDir="${tomcat.classes}"
|
||||||
|
filesId="files.tomcat-embed-websocket"
|
||||||
|
meta-inf="${tomcat.manifests}/tomcat-websocket.jar"
|
||||||
|
- addOSGi="true"
|
||||||
|
+ addOSGi="false"
|
||||||
|
addGraal="true"
|
||||||
|
graalPrefix="org.apache.tomcat.embed/tomcat-embed-websocket"
|
||||||
|
graalFiles="res/graal/tomcat-embed-websocket/native-image"
|
||||||
|
@@ -3716,6 +3716,7 @@ Read the Building page on the Apache Tom
|
||||||
|
<!-- Add bnd tasks to project -->
|
||||||
|
<path id="bnd.classpath">
|
||||||
|
<fileset file="${bnd.jar}" />
|
||||||
|
+ <fileset file="${bndannotation.jar}" />
|
||||||
|
</path>
|
||||||
|
|
||||||
|
<taskdef resource="aQute/bnd/ant/taskdef.properties" classpathref="bnd.classpath" />
|
@ -0,0 +1,9 @@
|
|||||||
|
--- res/META-INF/bootstrap.jar.manifest.orig 2010-04-06 10:11:09.000000000 -0600
|
||||||
|
+++ res/META-INF/bootstrap.jar.manifest 2010-04-06 10:45:56.000000000 -0600
|
||||||
|
@@ -1,6 +1,5 @@
|
||||||
|
Manifest-Version: 1.0
|
||||||
|
Main-Class: org.apache.catalina.startup.Bootstrap
|
||||||
|
-Class-Path: commons-daemon.jar
|
||||||
|
Specification-Title: Apache Tomcat Bootstrap
|
||||||
|
Specification-Version: @VERSION_MAJOR_MINOR@
|
||||||
|
Specification-Vendor: Apache Software Foundation
|
@ -0,0 +1,40 @@
|
|||||||
|
diff -up ./conf/catalina.policy.orig ./conf/catalina.policy
|
||||||
|
--- ./conf/catalina.policy.orig 2022-03-04 08:49:08.246538215 -0500
|
||||||
|
+++ ./conf/catalina.policy 2022-03-04 08:50:31.842356329 -0500
|
||||||
|
@@ -56,6 +56,36 @@ grant codeBase "file:${java.home}/lib/ex
|
||||||
|
// permission java.security.AllPermission;
|
||||||
|
//};
|
||||||
|
|
||||||
|
+// This permission is required when using javac to compile JSPs on Java 9
|
||||||
|
+// onwards
|
||||||
|
+grant codeBase "jrt:/jdk.compiler" {
|
||||||
|
+ permission java.security.AllPermission;
|
||||||
|
+};
|
||||||
|
+
|
||||||
|
+// ========== RHEL SPECIFIC CODE PERMISSIONS =======================================
|
||||||
|
+
|
||||||
|
+// Allowing everything in /usr/share/java allows too many unknowns to be permitted
|
||||||
|
+// Specifying the individual jars that tomcat needs to function with the security manager
|
||||||
|
+// is the safest way forward.
|
||||||
|
+grant codeBase "file:/usr/share/java/tomcat-servlet-4.0-api.jar" {
|
||||||
|
+ permission java.security.AllPermission;
|
||||||
|
+};
|
||||||
|
+grant codeBase "file:/usr/share/java/tomcat-jsp-2.3-api.jar" {
|
||||||
|
+ permission java.security.AllPermission;
|
||||||
|
+};
|
||||||
|
+grant codeBase "file:/usr/share/java/tomcat-el-3.0-api.jar" {
|
||||||
|
+ permission java.security.AllPermission;
|
||||||
|
+};
|
||||||
|
+grant codeBase "file:/usr/share/java/ant.jar" {
|
||||||
|
+ permission java.security.AllPermission;
|
||||||
|
+};
|
||||||
|
+grant codeBase "file:/usr/share/java/ant-launcher.jar" {
|
||||||
|
+ permission java.security.AllPermission;
|
||||||
|
+};
|
||||||
|
+grant codeBase "file:/usr/lib/jvm/java/lib/tools.jar" {
|
||||||
|
+ permission java.security.AllPermission;
|
||||||
|
+};
|
||||||
|
+
|
||||||
|
|
||||||
|
// ========== CATALINA CODE PERMISSIONS =======================================
|
||||||
|
|
@ -0,0 +1,49 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
#
|
||||||
|
# tomcat-digest script
|
||||||
|
# JPackage Project <http://www.jpackage.org/>
|
||||||
|
|
||||||
|
# Source functions library
|
||||||
|
if [ -f /usr/share/java-utils/java-functions ] ; then
|
||||||
|
. /usr/share/java-utils/java-functions
|
||||||
|
else
|
||||||
|
echo "Can't find functions library, aborting"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Get the tomcat config (use this for environment specific settings)
|
||||||
|
if [ -z "${TOMCAT_CFG}" ]; then
|
||||||
|
TOMCAT_CFG="/etc/tomcat/tomcat.conf"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -r "$TOMCAT_CFG" ]; then
|
||||||
|
. $TOMCAT_CFG
|
||||||
|
fi
|
||||||
|
|
||||||
|
set_javacmd
|
||||||
|
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/bin/bootstrap.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/bin/tomcat-juli.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/tomcat-api.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/tomcat-util.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/tomcat-util-scan.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/tomcat-coyote.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/catalina.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/servlet-api.jar"
|
||||||
|
export CLASSPATH
|
||||||
|
|
||||||
|
# Configuration
|
||||||
|
MAIN_CLASS="org.apache.catalina.startup.Tool"
|
||||||
|
BASE_FLAGS="-Dcatalina.home=\"$CATALINA_HOME\""
|
||||||
|
BASE_OPTIONS=""
|
||||||
|
#BASE_JARS="tomcat/tomcat-util tomcat/tomcat-util-scan"
|
||||||
|
#BASE_JARS="${BASE_JARS} tomcat/tomcat-coyote tomcat/catalina"
|
||||||
|
#BASE_JARS="${BASE_JARS} tomcat/servlet-api"
|
||||||
|
|
||||||
|
# Set parameters
|
||||||
|
#set_classpath $BASE_JARS
|
||||||
|
set_flags $BASE_FLAGS
|
||||||
|
set_options $BASE_OPTIONS
|
||||||
|
|
||||||
|
# Let's start
|
||||||
|
run -server org.apache.catalina.realm.RealmBase "$@"
|
@ -0,0 +1,17 @@
|
|||||||
|
--- conf/tomcat-users.xml~ 2008-01-28 17:41:06.000000000 -0500
|
||||||
|
+++ conf/tomcat-users.xml 2008-03-07 19:40:07.000000000 -0500
|
||||||
|
@@ -23,4 +23,14 @@
|
||||||
|
<user username="both" password="<must-be-changed>" roles="tomcat,role1"/>
|
||||||
|
<user username="role1" password="<must-be-changed>" roles="role1"/>
|
||||||
|
-->
|
||||||
|
+
|
||||||
|
+<!-- <role rolename="admin"/> -->
|
||||||
|
+<!-- <role rolename="admin-gui"/> -->
|
||||||
|
+<!-- <role rolename="admin-script"/> -->
|
||||||
|
+<!-- <role rolename="manager"/> -->
|
||||||
|
+<!-- <role rolename="manager-gui"/> -->
|
||||||
|
+<!-- <role rolename="manager-script"/> -->
|
||||||
|
+<!-- <role rolename="manager-jmx"/> -->
|
||||||
|
+<!-- <role rolename="manager-status"/> -->
|
||||||
|
+<!-- <user name="admin" password="<must-be-changed>" roles="admin,manager,admin-gui,admin-script,manager-gui,manager-script,manager-jmx,manager-status" /> -->
|
||||||
|
</tomcat-users>
|
@ -0,0 +1,49 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
#
|
||||||
|
# tomcat-digest script
|
||||||
|
# JPackage Project <http://www.jpackage.org/>
|
||||||
|
|
||||||
|
# Source functions library
|
||||||
|
if [ -f /usr/share/java-utils/java-functions ] ; then
|
||||||
|
. /usr/share/java-utils/java-functions
|
||||||
|
else
|
||||||
|
echo "Can't find functions library, aborting"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Get the tomcat config (use this for environment specific settings)
|
||||||
|
if [ -z "${TOMCAT_CFG}" ]; then
|
||||||
|
TOMCAT_CFG="/etc/tomcat/tomcat.conf"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -r "$TOMCAT_CFG" ]; then
|
||||||
|
. $TOMCAT_CFG
|
||||||
|
fi
|
||||||
|
|
||||||
|
set_javacmd
|
||||||
|
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/bin/bootstrap.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/bin/tomcat-juli.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/tomcat-api.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/tomcat-util.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/tomcat-util-scan.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/tomcat-coyote.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/catalina.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/lib/servlet-api.jar"
|
||||||
|
export CLASSPATH
|
||||||
|
|
||||||
|
# Configuration
|
||||||
|
MAIN_CLASS="org.apache.catalina.startup.Tool"
|
||||||
|
BASE_OPTIONS=""
|
||||||
|
BASE_FLAGS="-Dcatalina.home=\"$CATALINA_HOME\""
|
||||||
|
#BASE_JARS="tomcat/tomcat-util tomcat/tomcat-util-scan"
|
||||||
|
#BASE_JARS="${BASE_JARS} tomcat/tomcat-coyote tomcat/catalina"
|
||||||
|
#BASE_JARS="${BASE_JARS} tomcat/servlet-api"
|
||||||
|
|
||||||
|
# Set parameters
|
||||||
|
#set_classpath $BASE_JARS
|
||||||
|
set_flags $BASE_FLAGS
|
||||||
|
set_options $BASE_OPTIONS
|
||||||
|
|
||||||
|
# Let's start
|
||||||
|
run "$@"
|
@ -0,0 +1,61 @@
|
|||||||
|
# This will be loaded by systemd as an environment file,
|
||||||
|
# so please keep the syntax. For shell expansion support
|
||||||
|
# place your custom files as /etc/tomcat/conf.d/*.conf.
|
||||||
|
#
|
||||||
|
# There are 2 "classes" of startup behavior in this package.
|
||||||
|
# The old one, the default service named tomcat.service.
|
||||||
|
# The new named instances are called tomcat@instance.service.
|
||||||
|
#
|
||||||
|
# Use this file to change default values for all services.
|
||||||
|
# Change the service specific ones to affect only one service.
|
||||||
|
# For tomcat.service it's /etc/sysconfig/tomcat, for
|
||||||
|
# tomcat@instance it's /etc/sysconfig/tomcat@instance.
|
||||||
|
|
||||||
|
# This variable is used to figure out if config is loaded or not.
|
||||||
|
TOMCAT_CFG_LOADED="1"
|
||||||
|
|
||||||
|
# Where your java installation lives
|
||||||
|
#JAVA_HOME="/usr/lib/jvm/java"
|
||||||
|
|
||||||
|
# Where your tomcat installation lives
|
||||||
|
CATALINA_BASE="@@@TCHOME@@@"
|
||||||
|
CATALINA_HOME="@@@TCHOME@@@"
|
||||||
|
CATALINA_TMPDIR="@@@TCTEMP@@@"
|
||||||
|
|
||||||
|
# You can pass some parameters to java here if you wish to
|
||||||
|
#JAVA_OPTS="-Xminf0.1 -Xmaxf0.3"
|
||||||
|
|
||||||
|
# You can change your tomcat locale here
|
||||||
|
#LANG="en_US"
|
||||||
|
|
||||||
|
# Run tomcat under the Java Security Manager
|
||||||
|
SECURITY_MANAGER="false"
|
||||||
|
|
||||||
|
# DEPRECATED VARIABLES
|
||||||
|
#
|
||||||
|
# TOMCAT_USER has been deprecated. To update the tomcat process owner,
|
||||||
|
# please see User in tomcat.service.
|
||||||
|
#
|
||||||
|
# TOMCAT_GROUP has been deprecated. To update the tomcat process group,
|
||||||
|
# please see Group in tomcat.service.
|
||||||
|
#
|
||||||
|
# SHUTDOWN_WAIT has been deprecated. To change the shutdown wait time, set
|
||||||
|
# TimeoutStopSec in tomcat.service.
|
||||||
|
#
|
||||||
|
# SHUTDOWN_VERBOSE has been deprecated. There is no replacement for this behavior.
|
||||||
|
#
|
||||||
|
# CATALINA_PID has been deprecated. A replacement for this behavior is to set
|
||||||
|
# PIDFile in tomcat.service.
|
||||||
|
#
|
||||||
|
# CONNECTOR_PORT has been deprecated. There is no replacement for this behavior.
|
||||||
|
# Set init script output file
|
||||||
|
#
|
||||||
|
# TOMCAT_LOG has been deprecated. Output from start/stop/status operations are
|
||||||
|
# logged to the system's journal.
|
||||||
|
#
|
||||||
|
# LOGGING_CONFIG has been deprecated. To update the logging properties in use, use:
|
||||||
|
# LOGGING_PROPERTIES="${CATALINA_HOME}/lib/log4j.properties"
|
||||||
|
|
||||||
|
# If you wish to further customize your tomcat environment,
|
||||||
|
# put your own definitions here
|
||||||
|
# (i.e. LD_LIBRARY_PATH for some jdbc drivers)
|
@ -0,0 +1,21 @@
|
|||||||
|
# Systemd unit file for default tomcat
|
||||||
|
#
|
||||||
|
# To create clones of this service:
|
||||||
|
# DO NOTHING, use tomcat@.service instead.
|
||||||
|
|
||||||
|
[Unit]
|
||||||
|
Description=Apache Tomcat Web Application Container
|
||||||
|
After=syslog.target network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
EnvironmentFile=/etc/tomcat/tomcat.conf
|
||||||
|
Environment="NAME="
|
||||||
|
EnvironmentFile=-/etc/sysconfig/tomcat
|
||||||
|
ExecStart=/usr/libexec/tomcat/server start
|
||||||
|
SuccessExitStatus=143
|
||||||
|
User=tomcat
|
||||||
|
UMask=027
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
@ -0,0 +1,11 @@
|
|||||||
|
# Service-specific configuration file for tomcat. This will be sourced by
|
||||||
|
# systemd for the default service (tomcat.service)
|
||||||
|
# If you want to customize named instance, make a similar file
|
||||||
|
# and name it tomcat@instancename.
|
||||||
|
|
||||||
|
# You will not need to set this, usually. For default service it equals
|
||||||
|
# CATALINA_HOME. For named service, it equals ${TOMCATS_BASE}${NAME}
|
||||||
|
#CATALINA_BASE="@@@TCHOME@@@"
|
||||||
|
|
||||||
|
# Please take a look at /etc/tomcat/tomcat.conf to have an idea
|
||||||
|
# what you can override.
|
@ -0,0 +1,24 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
if [ "$1" = "version" ]; then
|
||||||
|
. /usr/libexec/tomcat/preamble
|
||||||
|
exec ${JAVACMD} -classpath ${CATALINA_HOME}/lib/catalina.jar \
|
||||||
|
org.apache.catalina.util.ServerInfo
|
||||||
|
fi
|
||||||
|
|
||||||
|
SRV="tomcat"
|
||||||
|
if [ -n "$2" ]; then
|
||||||
|
SRV="tomcat@$2"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$1" = "start" ]; then
|
||||||
|
systemctl start ${SRV}.service
|
||||||
|
elif [ "$1" = "stop" ]; then
|
||||||
|
systemctl stop ${SRV}.service
|
||||||
|
elif [ "$1" = "version" ]; then
|
||||||
|
${JAVACMD} -classpath ${CATALINA_HOME}/lib/catalina.jar \
|
||||||
|
org.apache.catalina.util.ServerInfo
|
||||||
|
else
|
||||||
|
echo "Usage: $0 {start|stop|version} [server-id]"
|
||||||
|
exit 1
|
||||||
|
fi
|
@ -0,0 +1,26 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
if [ -r /usr/share/java-utils/java-functions ]; then
|
||||||
|
. /usr/share/java-utils/java-functions
|
||||||
|
else
|
||||||
|
echo "Can't read Java functions library, aborting"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
_save_function() {
|
||||||
|
local ORIG_FUNC=$(declare -f $1)
|
||||||
|
local NEWNAME_FUNC="$2${ORIG_FUNC#$1}"
|
||||||
|
eval "$NEWNAME_FUNC"
|
||||||
|
}
|
||||||
|
|
||||||
|
_save_function run run_java
|
||||||
|
|
||||||
|
run() {
|
||||||
|
if [ "${USE_JSVC}" = "true" ] ; then
|
||||||
|
echo "JSVC support is not available with this Tomcat package."
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
run_java $@
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,26 @@
|
|||||||
|
# Systemd unit file for tomcat instances.
|
||||||
|
#
|
||||||
|
# To create clones of this service:
|
||||||
|
# 0. systemctl enable tomcat@name.service
|
||||||
|
# 1. create catalina.base directory structure in
|
||||||
|
# /var/lib/tomcats/name
|
||||||
|
# 2. profit.
|
||||||
|
|
||||||
|
[Unit]
|
||||||
|
Description=Apache Tomcat Web Application Container
|
||||||
|
After=syslog.target network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
EnvironmentFile=/etc/tomcat/tomcat.conf
|
||||||
|
Environment="NAME=%I"
|
||||||
|
EnvironmentFile=-/etc/sysconfig/tomcat@%I
|
||||||
|
ExecStart=/usr/libexec/tomcat/server start
|
||||||
|
ExecStop=/usr/libexec/tomcat/server stop
|
||||||
|
SuccessExitStatus=143
|
||||||
|
User=tomcat
|
||||||
|
UMask=027
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
|
@ -0,0 +1,56 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
. /usr/libexec/tomcat/functions
|
||||||
|
|
||||||
|
# Get the tomcat config (use this for environment specific settings)
|
||||||
|
|
||||||
|
if [ -z "${TOMCAT_CFG_LOADED}" ]; then
|
||||||
|
if [ -z "${TOMCAT_CFG}" ]; then
|
||||||
|
TOMCAT_CFG="/etc/tomcat/tomcat.conf"
|
||||||
|
fi
|
||||||
|
. $TOMCAT_CFG
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -d "${TOMCAT_CONFD=/etc/tomcat/conf.d}" ]; then
|
||||||
|
for file in ${TOMCAT_CONFD}/*.conf ; do
|
||||||
|
if [ -f "$file" ] ; then
|
||||||
|
. "$file"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z "$CATALINA_BASE" ]; then
|
||||||
|
if [ -n "$NAME" ]; then
|
||||||
|
if [ -z "$TOMCATS_BASE" ]; then
|
||||||
|
TOMCATS_BASE="/var/lib/tomcats/"
|
||||||
|
fi
|
||||||
|
CATALINA_BASE="${TOMCATS_BASE}${NAME}"
|
||||||
|
else
|
||||||
|
CATALINA_BASE="${CATALINA_HOME}"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
VERBOSE=1
|
||||||
|
set_javacmd
|
||||||
|
cd ${CATALINA_HOME}
|
||||||
|
# CLASSPATH munging
|
||||||
|
if [ ! -z "$CLASSPATH" ] ; then
|
||||||
|
CLASSPATH="$CLASSPATH":
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -n "$JSSE_HOME" ]; then
|
||||||
|
CLASSPATH="${CLASSPATH}$(build-classpath jcert jnet jsse 2>/dev/null):"
|
||||||
|
fi
|
||||||
|
CLASSPATH="${CLASSPATH}${CATALINA_HOME}/bin/bootstrap.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:${CATALINA_HOME}/bin/tomcat-juli.jar"
|
||||||
|
|
||||||
|
# Since ECJ is no longer available, add ant, ant-launcher, and tools jars to the
|
||||||
|
# classpath so that runtime compilation of JSPs still works.
|
||||||
|
CLASSPATH="${CLASSPATH}:/usr/share/java/ant.jar:/usr/share/java/ant-launcher.jar"
|
||||||
|
CLASSPATH="${CLASSPATH}:/usr/lib/jvm/java/lib/tools.jar"
|
||||||
|
|
||||||
|
if [ -z "$LOGGING_PROPERTIES" ] ; then
|
||||||
|
LOGGING_PROPERTIES="${CATALINA_BASE}/conf/logging.properties"
|
||||||
|
if [ ! -f "${LOGGING_PROPERTIES}" ] ; then
|
||||||
|
LOGGING_PROPERTIES="${CATALINA_HOME}/conf/logging.properties"
|
||||||
|
fi
|
||||||
|
fi
|
@ -0,0 +1,25 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
. /usr/libexec/tomcat/preamble
|
||||||
|
|
||||||
|
MAIN_CLASS=org.apache.catalina.startup.Bootstrap
|
||||||
|
|
||||||
|
FLAGS="$JAVA_OPTS"
|
||||||
|
OPTIONS="-Dcatalina.base=$CATALINA_BASE \
|
||||||
|
-Dcatalina.home=$CATALINA_HOME \
|
||||||
|
-Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS \
|
||||||
|
-Djava.io.tmpdir=$CATALINA_TMPDIR \
|
||||||
|
-Djava.util.logging.config.file=${LOGGING_PROPERTIES} \
|
||||||
|
-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager"
|
||||||
|
|
||||||
|
if [ "$1" = "start" ] ; then
|
||||||
|
FLAGS="${FLAGS} $CATALINA_OPTS"
|
||||||
|
if [ "${SECURITY_MANAGER}" = "true" ] ; then
|
||||||
|
OPTIONS="${OPTIONS} \
|
||||||
|
-Djava.security.manager \
|
||||||
|
-Djava.security.policy==${CATALINA_BASE}/conf/catalina.policy"
|
||||||
|
fi
|
||||||
|
run start
|
||||||
|
elif [ "$1" = "stop" ] ; then
|
||||||
|
run stop
|
||||||
|
fi
|
Loading…
Reference in new issue