Created
April 14, 2011 05:50
-
-
Save claylo/918961 to your computer and use it in GitHub Desktop.
launchd wrapper for Atlassian Crowd on Mac OS X
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
function shutdown() | |
{ | |
date | |
echo "Shutting down Crowd" | |
$CATALINA_HOME/bin/catalina.sh stop | |
} | |
date | |
echo "Starting Crowd" | |
export CATALINA_PID=/tmp/$$ | |
. $CATALINA_HOME/bin/catalina.sh start | |
# allow any signal that would kill a process to stop Tomcat | |
trap shutdown HUP INT QUIT ABRT KILL ALRM TERM TSTP | |
echo "Waiting for `cat $CATALINA_PID`" | |
wait `cat $CATALINA_PID` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment