From 04e6ced3985b4ad01ceb217897f0ccb7e94b0623 Mon Sep 17 00:00:00 2001 From: Sam Hague Date: Mon, 5 Mar 2018 17:20:19 -0500 Subject: [PATCH] fix ocata stack by looking for rabbitmq pid Change-Id: I1277b8c172fffd365a2da51362f22d935c78c550 Signed-off-by: Sam Hague --- .../integration-deploy-openstack-run-test.sh | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/jjb/integration/integration-deploy-openstack-run-test.sh b/jjb/integration/integration-deploy-openstack-run-test.sh index 2521f80d9..f74e416bc 100644 --- a/jjb/integration/integration-deploy-openstack-run-test.sh +++ b/jjb/integration/integration-deploy-openstack-run-test.sh @@ -553,6 +553,7 @@ EOF mkdir -p ${WORKSPACE}/archives mv /tmp/changes.txt ${WORKSPACE}/archives + mv ${WORKSPACE}/rabbit.txt ${WORKSPACE}/archives sleep 5 # FIXME: Do not create .tar and gzip before copying. @@ -775,10 +776,16 @@ function get_service () { # Check if rabbitmq is ready by looking for a pid in it's status. # The function returns the status of the grep command which callers can check. function is_rabbitmq_ready() { - local -r ip=$1 + local -r ip=${1} + local grepfor="nova_cell1" rm -f rabbit.txt - ${SSH} ${ip} "sudo rabbitmqctl list_vhosts" > rabbit.txt - grep nova_cell1 rabbit.txt + if [ "${OPENSTACK_BRANCH}" == "stable/ocata" ]; then + ${SSH} ${ip} "sudo rabbitmqctl status" > rabbit.txt + grepfor="pid" + else + ${SSH} ${ip} "sudo rabbitmqctl list_vhosts" > rabbit.txt + fi + grep ${grepfor} rabbit.txt } # retry the given command ($3) until success for a number of iterations ($1) -- 2.36.6