ccm und ccm-run Skript so angepasst, dass beide Skripte mit den meisten Linux-Distributionen kompatibel sind.

git-svn-id: https://svn.libreccm.org/ccm/trunk@1233 8810af33-2d31-482b-a856-94f89814c4df
master
jensp 2011-11-09 18:38:41 +00:00
parent c8ef06aa65
commit b4258bf9ef
2 changed files with 53 additions and 20 deletions

View File

@ -17,15 +17,16 @@ CCM_HOME_DIR="../.."
if [[ -z "$CATALINA_HOME" ]] ; then if [[ -z "$CATALINA_HOME" ]] ; then
echo CATALINE_HOME not set. Guessing ... echo CATALINE_HOME not set. Guessing ...
if [ -f /etc/tomcat6/tomcat6.conf ] if [ -d /usr/share/tomcat6 ]
then then
. /etc/tomcat6/tomcat6.conf CATALINA_HOME = "/usr/share/tomcat6"
echo elif [ -d /usr/share/tomcat-6 ]
echo Using CATALINA_HOME = $CATALINA_HOME then
echo If this doesn\'t work use CATALINA_HOME = "/usr/share/tomcat-6"
echo export CATALINA_HOME=/path/to/tomcat/installation elif [ -d /opt/tomcat6 ]
echo to point us to the correct location. then
else CATALINA_HOME = "/opt/tomcat6"
else
echo echo
echo =================================================== echo ===================================================
echo Environment variable CATALINA_HOME not set. We need echo Environment variable CATALINA_HOME not set. We need
@ -38,6 +39,13 @@ if [[ -z "$CATALINA_HOME" ]] ; then
echo echo
exit 1 exit 1
fi fi
echo
echo Using CATALINA_HOME = $CATALINA_HOME
echo If this doesn\'t work use
echo export CATALINA_HOME=/path/to/tomcat/installation
echo to point us to the correct location.
fi fi
CATALINA_LIB_DIR="${CATALINA_HOME}/lib" CATALINA_LIB_DIR="${CATALINA_HOME}/lib"

View File

@ -10,16 +10,41 @@
# PATH, you have to adjust the paths. # PATH, you have to adjust the paths.
CCM_LIB_DIR="../lib" CCM_LIB_DIR="../lib"
CCM_HOME_DIR="../.." CCM_HOME_DIR="../.."
# Path of the lib directory of the Tomcat Server which runs the CCM installation.
# If the CATALINA_HOME enviroment variable is not set on your system you have # We need CATALINA_HOME environment variable to access Tomcat's lib dir.
# either to set this environment variable (recommened) if [[ -z "$CATALINA_HOME" ]] ; then
# to adjust this path to point to the lib directory of your Tomcat installation echo CATALINE_HOME not set. Guessing ...
# (if you installed the Tomcat using the package manager of your distribution
# this is usally /usr/share/tomcat6/lib) if [ -d /usr/share/tomcat6 ]
# To set an environment variable you have usally to add an file to the /etc/profile.d then
# directory, for example tomcat.sh. In this file, you can set environment variables CATALINA_HOME = "/usr/share/tomcat6"
# using the 'export' command. This line might look like this: elif [ -d /usr/share/tomcat-6 ]
# export CATALINA_HOME=/usr/share/tomcat6/lib then
CATALINA_HOME = "/usr/share/tomcat-6"
elif [ -d /opt/tomcat6 ]
then
CATALINA_HOME = "/opt/tomcat6"
else
echo
echo ===================================================
echo Environment variable CATALINA_HOME not set. We need
echo to know the location of Tomcat\'s lib directory.
echo So use
echo export CATALINA_HOME=/path/to/tomcat/installation
echo to point us to the correct location and run ccm
echo again.
echo ===================================================
echo
exit 1
fi
echo
echo Using CATALINA_HOME = $CATALINA_HOME
echo If this doesn\'t work use
echo export CATALINA_HOME=/path/to/tomcat/installation
echo to point us to the correct location.
fi
CATALINA_LIB_DIR="${CATALINA_HOME}/lib" CATALINA_LIB_DIR="${CATALINA_HOME}/lib"
# Script logic starts here # Script logic starts here