From 4efc65cffea956034a7e7725e8f4d4005a7e931e Mon Sep 17 00:00:00 2001 From: James Slagle Date: Fri, 31 Aug 2018 17:09:58 -0400 Subject: [PATCH] Use overcloud status for failure checking We need to determine overcloud status with the new command starting in rocky, and let that guard whether we check for failures or not. Change-Id: I69843e8e1195b2a4ae75d388610d35bbafae5af4 --- roles/overcloud-deploy/templates/overcloud-deploy.sh.j2 | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/roles/overcloud-deploy/templates/overcloud-deploy.sh.j2 b/roles/overcloud-deploy/templates/overcloud-deploy.sh.j2 index 6cdfe3f70..0ff019cd2 100644 --- a/roles/overcloud-deploy/templates/overcloud-deploy.sh.j2 +++ b/roles/overcloud-deploy/templates/overcloud-deploy.sh.j2 @@ -49,8 +49,6 @@ elif ! openstack stack list | grep -Eq '(CREATE|UPDATE)_COMPLETE'; then {%if release not in ['mitaka', 'liberty'] %} # get the failures list openstack stack failures list overcloud --long > {{ failed_deployment_list }} || true - # NOTE(emilien) "openstack overcloud failures" was introduced in Rocky - openstack overcloud failures >> {{ failed_deployment_list }} || true {% endif %} # get any puppet related errors @@ -72,5 +70,10 @@ elif ! openstack stack list | grep -Eq '(CREATE|UPDATE)_COMPLETE'; then # We need to exit with 1 because of the above || true done exit 1 +{%if release in ['rocky', 'master'] %} +elif ! openstack overcloud status | grep -Eq 'DEPLOY_SUCCESS'; then + # NOTE(emilien) "openstack overcloud failures" was introduced in Rocky + openstack overcloud failures >> {{ failed_deployment_list }} || true +{% endif %} fi exit $status_code