summaryrefslogtreecommitdiffstats
path: root/jjb/yardstick
diff options
context:
space:
mode:
authorjose.lausuch <jose.lausuch@ericsson.com>2016-01-14 20:24:05 +0000
committerGerrit Code Review <gerrit@172.30.200.206>2016-01-14 20:24:05 +0000
commit4f723be944e52dae79c2e6377c63a5b89b69e72a (patch)
tree1f17324d4837563c4e4cc3e1e24bcd72042d32cc /jjb/yardstick
parentc0e6f4c1b34bfc376580f82fad401e3c6f4a43ba (diff)
parentec22e929558fd2251c37b5b7cb77f63e4a4bd64a (diff)
Merge "test: fix output redirection if when CI_DEBUG"
Diffstat (limited to 'jjb/yardstick')
-rw-r--r--jjb/yardstick/yardstick-ci-jobs.yml13
1 files changed, 7 insertions, 6 deletions
diff --git a/jjb/yardstick/yardstick-ci-jobs.yml b/jjb/yardstick/yardstick-ci-jobs.yml
index 0678ef0ef..5159d3026 100644
--- a/jjb/yardstick/yardstick-ci-jobs.yml
+++ b/jjb/yardstick/yardstick-ci-jobs.yml
@@ -117,7 +117,7 @@
- shell: |
#!/bin/bash
set -e
- [[ $CI_DEBUG == true ]] && redirect="" || redirect=">/dev/null"
+ [[ $CI_DEBUG == true ]] && redirect="/dev/stdout" || redirect="/dev/null"
# labconfig is used only for joid
labconfig=""
@@ -141,7 +141,7 @@
envs="-e INSTALLER_TYPE=${INSTALLER_TYPE} -e INSTALLER_IP=${INSTALLER_IP} -e NODE_NAME=${NODE_NAME} -e EXTERNAL_NETWORK=${EXTERNAL_NETWORK} -e YARDSTICK_BRANCH=${GIT_BRANCH##origin/}"
# Pull the latest image
- docker pull opnfv/yardstick $redirect
+ docker pull opnfv/yardstick >$redirect
# Run docker
cmd="sudo docker run ${opts} ${envs} ${labconfig} ${sshkey} opnfv/yardstick run_tests.sh ${YARDSTICK_DB_BACKEND} ${YARDSTICK_SUITE_NAME}"
@@ -161,14 +161,14 @@
builders:
- shell: |
#!/bin/bash
- [[ $CI_DEBUG == true ]] && redirect="" || redirect=">/dev/null"
+ [[ $CI_DEBUG == true ]] && redirect="/dev/stdout" || redirect="/dev/null"
echo "Cleaning up docker containers/images..."
# Remove previous running containers if exist
if [[ ! -z $(docker ps -a | grep opnfv/yardstick) ]]; then
echo "Removing existing opnfv/yardstick containers..."
- docker ps | grep opnfv/yardstick | awk '{print $1}' | xargs docker stop $redirect
- docker ps -a | grep opnfv/yardstick | awk '{print $1}' | xargs docker rm $redirect
+ docker ps -a | grep opnfv/yardstick | awk '{print $1}' | xargs docker rm -f >$redirect
+
fi
# Remove existing images if exist
@@ -178,7 +178,8 @@
image_tags=($(docker images | grep opnfv/yardstick | awk '{print $2}'))
for tag in "${image_tags[@]}"; do
echo "Removing docker image opnfv/yardstick:$tag..."
- docker rmi opnfv/yardstick:$tag $redirect
+ docker rmi opnfv/yardstick:$tag >$redirect
+
done
fi
########################