diff options
-rwxr-xr-x | lava-slave/scripts/setup.sh | 6 | ||||
-rwxr-xr-x | lavalab-gen.py | 2 |
2 files changed, 5 insertions, 3 deletions
diff --git a/lava-slave/scripts/setup.sh b/lava-slave/scripts/setup.sh index c39fdc4..58672c3 100755 --- a/lava-slave/scripts/setup.sh +++ b/lava-slave/scripts/setup.sh @@ -22,7 +22,7 @@ echo "Dynamic slave for $LAVA_MASTER ($LAVA_MASTER_URI)" LAVACLIOPTS="--uri $LAVA_MASTER_URI" # do a sort of ping for letting master to be up -TIMEOUT=300 +TIMEOUT=1200 while [ $TIMEOUT -ge 1 ]; do STEP=2 @@ -30,7 +30,7 @@ do if [ $? -eq 0 ];then TIMEOUT=0 else - echo "Wait for master...." + echo "Wait for master.... (${TIMEOUT}s remains)" sleep $STEP fi TIMEOUT=$(($TIMEOUT-$STEP)) @@ -50,10 +50,12 @@ fi lavacli $LAVACLIOPTS device-types list > /tmp/device-types.list if [ $? -ne 0 ];then + echo "ERROR: fail to list device-types" exit 1 fi lavacli $LAVACLIOPTS devices list -a > /tmp/devices.list if [ $? -ne 0 ];then + echo "ERROR: fail to list devices" exit 1 fi for worker in $(ls /root/devices/) diff --git a/lavalab-gen.py b/lavalab-gen.py index ea4417d..96d25c1 100755 --- a/lavalab-gen.py +++ b/lavalab-gen.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # from __future__ import print_function import os, sys, time |