Browse Source

provide workers.properties file and configure status and tomcat workers there

master
parent
commit
120b6a4032
  1. 28
      apache-tomcat/apache-tomcat.conf
  2. 6
      apache-tomcat/apache-tomcat.spec
  3. 16
      apache-tomcat/apache-tomcat.workers

28
apache-tomcat/apache-tomcat.conf

@ -3,17 +3,27 @@
##
# load DSO
LoadModule jk_module @l_prefix@/libexec/apache/mod_jk.so
LoadModule jk_module @l_prefix@/libexec/apache/mod_jk.so
# workers configuration
JkWorkersFile @l_prefix@/libexec/tomcat/conf/workers.properties
JkWorkersFile @l_prefix@/etc/apache-tomcat/workers.properties
# logging
JkLogFile @l_prefix@/var/apache-tomcat/apache-tomcat.log
JkLogLevel warn
# run-time & logging
JkShmFile @l_prefix@/var/apache-tomcat/mod_jk.shm
JkLogFile @l_prefix@/var/apache-tomcat/mod_jk.log
JkLogLevel warn
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
# assigning URLs to Tomcat
JkMount /*.jsp ajp13
JkMount /servlet/* ajp13
JkMount /examples/* ajp13
# mount worker "status" (internal)
<Location /jk-status/>
JkMount status
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Location>
# mount worker "tomcat" (remote)
JkMount /*.jsp tomcat
JkMount /servlet/* tomcat
JkMount /examples/* tomcat

6
apache-tomcat/apache-tomcat.spec

@ -38,6 +38,7 @@ Release: 20070704
# list of sources
Source0: http://www.apache.org/dist/tomcat/tomcat-connectors/jk/source/jk-%{version}/tomcat-connectors-%{version}-src.tar.gz
Source1: apache-tomcat.conf
Source2: apache-tomcat.workers
# build information
Prefix: %{l_prefix}
@ -83,11 +84,15 @@ AutoReqProv: no
# create installation tree
%{l_shtool} mkdir -f -p -m 755 \
$RPM_BUILD_ROOT%{l_prefix}/etc/apache-tomcat \
$RPM_BUILD_ROOT%{l_prefix}/etc/apache/apache.d \
$RPM_BUILD_ROOT%{l_prefix}/libexec/apache \
$RPM_BUILD_ROOT%{l_prefix}/var/apache-tomcat
# install config
%{l_shtool} install -c -m 644 %{l_value -s -a} \
%{SOURCE apache-tomcat.workers} \
$RPM_BUILD_ROOT%{l_prefix}/etc/apache-tomcat/workers.properties
%{l_shtool} install -c -m 644 %{l_value -s -a} \
%{SOURCE apache-tomcat.conf} \
$RPM_BUILD_ROOT%{l_prefix}/etc/apache/apache.d/
@ -100,6 +105,7 @@ AutoReqProv: no
# determine installation files
%{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
%{l_files_std} \
'%config %{l_prefix}/etc/apache-tomcat/workers.properties' \
'%config %{l_prefix}/etc/apache/apache.d/apache-tomcat.conf'
%files -f files

16
apache-tomcat/apache-tomcat.workers

@ -0,0 +1,16 @@
##
## workers.properties -- Apache Tomcat/mod_jk workers properties
##
# list of workers
worker.list=status,tomcat
# worker "status"
worker.list=status
worker.status.type=status
# worker "tomcat"
worker.tomcat.type=ajp13
worker.tomcat.host=127.0.0.1
worker.tomcat.port=8009
Loading…
Cancel
Save