X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=run_tests.sh;h=3bf18c628c35d5fbb23d8ae11a30cd7bed460a3f;hb=d5f7a33fc251788320b03ae2217611f14ec68fab;hp=b92e9f2931e4a1002859843b9712dc0c8f6f9b52;hpb=bde702f95563cf953c32f9bfd0587083a3fea26d;p=bottlenecks.git diff --git a/run_tests.sh b/run_tests.sh index b92e9f29..3bf18c62 100755 --- a/run_tests.sh +++ b/run_tests.sh @@ -17,17 +17,16 @@ where: -h|--help show the help text -s|--teststory run specific test story one of the following: - (rubbos, vstf, posca_factor_test) + (posca_factor_test) user can also define their own test story and pass as var to this file, please refer to testsuites/posca/testsuite_story/ for details -c|--testcase run specific test case one of the following: - (posca_factor_system_bandwidth, posca_factor_ping) + (posca_factor_ping, posca_factor_soak_throughputs, ...) --cleanup cleanup test dockers runing when test is done (false by default) --report push results to DB (false by default) examples: - $(basename "$0") $(basename "$0") -s posca_factor_test" # Define global variables @@ -42,11 +41,11 @@ cleanup=false # Define alias for log printing info () { - logger -s -t "bottlenecks.info" "$*" + logger -s -t "BOTTLENECKS INFO" "$*" } error () { - logger -s -t "bottlenecks.error" "$*" + logger -s -t "BOTTLENECKS ERROR" "$*" exit 1 } @@ -103,13 +102,13 @@ function run_test(){ If you want to run VSTF, please refer to earlier releases." ;; *) - info "Composing up dockers" - docker-compose -f /home/opnfv/bottlenecks/docker/bottleneck-compose/docker-compose.yml up -d - info "Pulling tutum/influxdb for yardstick" - docker pull tutum/influxdb:0.13 - sleep 5 info "Running posca $test_level: $test_exec" - docker exec bottleneckcompose_bottlenecks_1 python ${POSCA_SUITE}/../run_testsuite.py $test_level $test_exec $REPORT + opts="--privileged=true -id" + docker_volume="-v /var/run/docker.sock:/var/run/docker.sock -v /tmp:/tmp" + docker run $opts --name bottlenecks-load-master $docker_volume opnfv/bottlenecks:latest /bin/bash + sleep 5 + POSCA_SCRIPT="/home/opnfv/bottlenecks/testsuites/posca" + docker exec bottlenecks-load-master python ${POSCA_SCRIPT}/../run_testsuite.py ${test_level} ${test_exec} ${REPORT} ;; esac } @@ -177,7 +176,8 @@ fi # Clean up testing dockers if [[ ${cleanup} == true ]]; then info "Cleaning up docker-compose images and dockers" - docker-compose -f $BASEDIR/docker/bottleneck-compose/docker-compose.yml down --rmi all bash ${BASEDIR}/docker/docker_cleanup.sh -d influxdb --debug bash ${BASEDIR}/docker/docker_cleanup.sh -d bottlenecks --debug + bash ${BASEDIR}/docker/docker_cleanup.sh -d yardstick --debug + bash ${BASEDIR}/docker/docker_cleanup.sh -d elk --debug fi