Check for post_test_hook.sh in placement job

The post_test_hook.sh used in the placement job for
nova didn't exist until Ocata so the placement job
always fails in stable/newton changes.

This change adds a check for the file before executing
it and also changes the path prefix to use the standard
$BASE variable like many other jobs.

Change-Id: I8bad5aefada01041efef4d37adde980c9358639c
This commit is contained in:
Matt Riedemann 2017-01-11 21:44:18 -05:00
parent 1ff2f68844
commit d619c95bea

View File

@ -76,7 +76,9 @@
export OVERRIDE_ZUUL_BRANCH=$BRANCH_OVERRIDE
fi
function post_test_hook {{
/opt/stack/new/nova/tools/hooks/post_test_hook.sh
if [ -f $BASE/new/nova/tools/hooks/post_test_hook.sh ]; then
$BASE/new/nova/tools/hooks/post_test_hook.sh
fi
}}
export -f post_test_hook
cp devstack-gate/devstack-vm-gate-wrap.sh ./safe-devstack-vm-gate-wrap.sh