summaryrefslogtreecommitdiffstats
path: root/ci/envs
diff options
context:
space:
mode:
Diffstat (limited to 'ci/envs')
-rwxr-xr-xci/envs/cyclictest.sh7
-rwxr-xr-xci/envs/utils.sh8
2 files changed, 13 insertions, 2 deletions
diff --git a/ci/envs/cyclictest.sh b/ci/envs/cyclictest.sh
index 747f34758..4c5440d71 100755
--- a/ci/envs/cyclictest.sh
+++ b/ci/envs/cyclictest.sh
@@ -7,7 +7,7 @@
source utils.sh
HOST_IP=$( getHostIP )
-pod_config='/opt/pod.yaml'
+pod_config='/opt/scripts/pod.yaml'
cyclictest_context_file='/opt/cyclictest-node-context.yaml'
if [ ! -f ${pod_config} ] ; then
@@ -25,5 +25,10 @@ sudo ssh root@$HOST_IP "cp /root/images/guest1.qcow2 /root/"
#Running cyclictest through yardstick
yardstick -d task start ${cyclictest_context_file}
+output=$?
chmod 777 /tmp/yardstick.out
cat /tmp/yardstick.out > /opt/yardstick.out
+if [ $output != 0 ];then
+ echo "Someproblem with execution of Yardstick"
+ exit 1
+fi
diff --git a/ci/envs/utils.sh b/ci/envs/utils.sh
index f582b5aac..5db55bef8 100755
--- a/ci/envs/utils.sh
+++ b/ci/envs/utils.sh
@@ -18,6 +18,12 @@ function getKernelVersion {
#Get the IP address from pod.yaml file (example ip : 10.2.117.23)
function getHostIP {
- HOST_IP=`grep 'ip' $WORKSPACE/tests/pod.yaml | awk -F ': ' '{print $NF}' | tail -1`
+ host_dir="/root/workspace/scripts/"
+ container_dir="/opt/scripts/"
+ if [ -d "$container_dir" ];then
+ HOST_IP=`grep 'ip' $container_dir/pod.yaml | awk -F ': ' '{print $NF}' | tail -1`
+ elif [ -d "$host_dir" ];then
+ HOST_IP=`grep 'ip' $host_dir/pod.yaml | awk -F ': ' '{print $NF}' | tail -1`
+ fi
echo $HOST_IP
}