Added stop script and updated build script to also copy start and stop script

This commit is contained in:
Simon Pamies committed 2013-04-14 00:10:46 +08:00
1 parent f0d7c550e2
commit 3969120fdd
3 files changed
+20

No files matched your search

+1
View File
@@ -2,3 +2,4 @@ scriptdir=`dirname "$0"`
LIB_DIR=`pwd`/native-libraries
echo scriptdir is $scriptdir and LIB_DIR is $LIB_DIR
nohup "$JAVA_HOME/bin/java" -XX:+UseMembar -Dfile.encoding=cp1252 -Djetty.home=$scriptdir/configuration/jetty -Djava.util.logging.config.file=$scriptdir/configuration/logging.properties -Djava.library.path=$LIB_DIR -Xmx8192m -jar plugins/org.eclipse.equinox.launcher_1.2.0.v20110502.jar -console 14886 -configuration ./ -clean &
echo "Started MASTER on port 14886 - use telnet localhost 14886 to connect to the OSGi console"
+13
View File
@@ -0,0 +1,13 @@
#!/bin/bash
OSGI_TELNET_PORT=14886
TELNET_ACTIVE=`netstat -tlnp 2>/dev/null | grep ":$OSGI_TELNET_PORT"`
if [[ $OSGI_TELNET_PORT == "" ]] || [[ $TELNET_ACTIVE == "" ]]; then
echo "Could not find server on telnet port $OSGI_TELNET_PORT. Perhaps server is not running?"
exit
fi
NC_CMD="nc -t 127.0.0.1 $OSGI_TELNET_PORT"
echo -n exit | $NC_CMD > /dev/null
echo "Stopped server MASTER"