From 8588d321201b1713a8b95704e9c6abd39eb80609 Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Tue, 23 Jun 2009 15:00:10 -0700 Subject: pass through server and path args to daemons --- scripts/startdaemons.sh | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/scripts/startdaemons.sh b/scripts/startdaemons.sh index 053c4f8ee..4e87694fb 100755 --- a/scripts/startdaemons.sh +++ b/scripts/startdaemons.sh @@ -23,9 +23,19 @@ DIR=`dirname $0` DAEMONS=`php $DIR/getvaliddaemons.php` +ARGS= + +if [ $# -gt 0 ]; then + ARGS="$ARGS -s$1" +fi + +if [ $# -gt 1 ]; then + ARGS="$ARGS -p$2" +fi + for f in $DAEMONS; do echo -n "Starting $f..."; - php $DIR/$f + php $DIR/$f $ARGS echo "DONE." done -- cgit v1.2.3-54-g00ecf From f88d767f493c5780476450d92ddb8f27a6ea6caa Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Tue, 23 Jun 2009 16:44:00 -0700 Subject: add args to daemons fetch --- scripts/startdaemons.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/startdaemons.sh b/scripts/startdaemons.sh index 4e87694fb..7609abec4 100755 --- a/scripts/startdaemons.sh +++ b/scripts/startdaemons.sh @@ -20,9 +20,6 @@ # This program tries to start the daemons for Laconica. # Note that the 'maildaemon' needs to run as a mail filter. -DIR=`dirname $0` -DAEMONS=`php $DIR/getvaliddaemons.php` - ARGS= if [ $# -gt 0 ]; then @@ -33,6 +30,9 @@ if [ $# -gt 1 ]; then ARGS="$ARGS -p$2" fi +DIR=`dirname $0` +DAEMONS=`php $DIR/getvaliddaemons.php $ARGS` + for f in $DAEMONS; do echo -n "Starting $f..."; -- cgit v1.2.3-54-g00ecf