From 2823e335314c65a5ac7d74bcaa6760427c52ee04 Mon Sep 17 00:00:00 2001 From: Michael Peter Christen Date: Tue, 29 May 2012 13:08:27 +0200 Subject: [PATCH] fixes for wrong port number in shell scripts --- bin/checkalive.sh | 3 ++- bin/graphicstest.sh | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/bin/checkalive.sh b/bin/checkalive.sh index c86565194..56d836c00 100755 --- a/bin/checkalive.sh +++ b/bin/checkalive.sh @@ -3,7 +3,8 @@ # add in /etc/crontab # 0 * * * * yacy cd /home/yacy/production/bin && ./checkalive.sh -RESULT=`wget -t 1 --spider http://localhost:8090/Status.html 2>&1` +port=$(grep ^port= ../DATA/SETTINGS/yacy.conf |cut -d= -f2) +RESULT=`wget -t 1 --spider http://localhost:$port/Status.html 2>&1` FLAG=0 for x in $RESULT; do diff --git a/bin/graphicstest.sh b/bin/graphicstest.sh index c75f6f414..384d2d489 100755 --- a/bin/graphicstest.sh +++ b/bin/graphicstest.sh @@ -1,4 +1,5 @@ +port=$(grep ^port= ../DATA/SETTINGS/yacy.conf |cut -d= -f2) while [ 1 = 1 ] do -curl "http://localhost:8090/NetworkPicture.png?width=768&height=576&bgcolor=FFFFFF" > /dev/null +curl "http://localhost:$port/NetworkPicture.png?width=768&height=576&bgcolor=FFFFFF" > /dev/null done