aboutsummaryrefslogtreecommitdiffstats
path: root/bin/srt
diff options
context:
space:
mode:
Diffstat (limited to 'bin/srt')
-rwxr-xr-xbin/srt19
1 files changed, 19 insertions, 0 deletions
diff --git a/bin/srt b/bin/srt
index 7af2491..41753b7 100755
--- a/bin/srt
+++ b/bin/srt
@@ -22,6 +22,7 @@ HELP="
Usage: source srt start|stop [webport=<address:port>]
Optional arguments:
[webport] Set the SRTool server port (default: localhost:8000)
+ [noautoupdate] Disable the auto update server
"
databaseCheck()
@@ -76,6 +77,11 @@ webserverKillAll()
rm ${pidfile}
fi
done
+
+ # Stop the Update app
+ if [ 0 -eq $no_auto_update ] ; then
+ ./bin/common/srtool_update.py --cron-stop
+ fi
}
webserverStartAll()
@@ -107,6 +113,11 @@ webserverStartAll()
echo "SRTool webserver started at http://$ADDR_PORT"
fi
+ # Start the Update app
+ if [ 0 -eq $no_auto_update ] ; then
+ ./bin/common/srtool_update.py --cron-start > /dev/null 2>&1 &
+ echo "SRTool update service started at PID $!"
+ fi
return $retval
}
@@ -186,6 +197,11 @@ touch $SRT_BASE_DIR/update_logs/master_log.txt
ADDR_PORT="localhost:8000"
unset CMD
manage_cmd=""
+if [ "1" = "$SRT_SKIP_AUTOUPDATE" ] ; then
+ no_auto_update=1
+else
+ no_auto_update=0
+fi
for param in $*; do
case $param in
start )
@@ -207,6 +223,9 @@ for param in $*; do
ADDR_PORT="localhost:$PORT"
fi
;;
+ noautoupdate )
+ no_auto_update=1
+ ;;
--help)
echo "$HELP"
exit 0