From 200d49bc4aea2167ff292a885f90ee13c6231e59 Mon Sep 17 00:00:00 2001 From: Sebastien Douheret Date: Sat, 13 May 2017 23:23:42 +0200 Subject: Allow to not start server (useful for debugging). Signed-off-by: Sebastien Douheret --- scripts/xds-start-server.sh | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) (limited to 'scripts') diff --git a/scripts/xds-start-server.sh b/scripts/xds-start-server.sh index 5a3cba7..6888473 100755 --- a/scripts/xds-start-server.sh +++ b/scripts/xds-start-server.sh @@ -41,10 +41,16 @@ pid_sync=$(jobs -p) echo "pid=${pid_sync}" echo "" -sleep 1 - -echo "### Start XDS server" -$BINDIR/xds-server --config $XDS_CONFFILE -log $LOGLEVEL > $LOG_XDS 2>&1 & -pid_xds=$(jobs -p) -echo "pid=${pid_xds}" +if [ "$1" == "-noserver" ]; then + echo "## XDS server NOT STARTED" + echo " Command to start it:" + echo " $BINDIR/xds-server --config $XDS_CONFFILE -log $LOGLEVEL > $LOG_XDS 2>&1" +else + # Wait a bit so make connection to Syncthing possible + sleep 1 + echo "### Start XDS server" + $BINDIR/xds-server --config $XDS_CONFFILE -log $LOGLEVEL > $LOG_XDS 2>&1 & + pid_xds=$(jobs -p) + echo "pid=${pid_xds}" +fi echo "" -- cgit 1.2.3-korg