From: kinkwan_tsui Date: Thu, 30 May 2019 13:25:53 +0000 (+0300) Subject: adding a loop and delay time X-Git-Url: https://gerrit.akraino.org/r/gitweb?p=rec.git;a=commitdiff_plain;h=b9b9fff464110abf2659acef5a85576dbb905046 adding a loop and delay time Change-Id: I2abd680fa9533219de4d462922507f4826d837fa Signed-off-by: kinkwan_tsui --- diff --git a/workflows/nanobot.sh b/workflows/nanobot.sh old mode 100755 new mode 100644 index ba13b4b..cd54507 --- a/workflows/nanobot.sh +++ b/workflows/nanobot.sh @@ -60,6 +60,7 @@ kubectl logs $nanobot_pod -n rictest #--------------kill helm--------------------------------------------------------------------- pkill helm #------------checking the status of the rictest pod-------------------------------------- +sleep 30 command="$(kubectl get po --no-headers --namespace=rictest --field-selector status.phase=Completed 2> /dev/null)" if [[ $command != "" ]]; then exit 1 diff --git a/workflows/ric_automation.sh b/workflows/ric_automation.sh old mode 100755 new mode 100644 index 46768e6..795436f --- a/workflows/ric_automation.sh +++ b/workflows/ric_automation.sh @@ -128,9 +128,17 @@ bash -x ./ric_install.sh #--------------kill helm--------------------------------------------------------------------- pkill helm #-------------checking the output------------------------------------------------------------- +for i in `seq 1 10` +do command="$(kubectl get po --no-headers --namespace=ricplatform --field-selector status.phase!=Running 2> /dev/null)" if [[ $command != "" ]]; then - exit 1 + sleep 30 +else + exit 0 fi +done +exit 1 + + diff --git a/workflows/robot_test_ric.sh b/workflows/robot_test_ric.sh old mode 100755 new mode 100644 index fff75eb..fe767ea --- a/workflows/robot_test_ric.sh +++ b/workflows/robot_test_ric.sh @@ -58,6 +58,7 @@ bash ete-k8s.sh ricplatform health #--------------kill helm--------------------------------------------------------------------- pkill helm #----------checking the status of the pods------------------ +sleep 30 command="$(kubectl get po --no-headers --namespace=ricplatform --field-selector status.phase!=Running 2> /dev/null)" if [[ $command != "" ]]; then exit 1