From 46f595b4621e4877aac493a7bec0b3389cf48017 Mon Sep 17 00:00:00 2001 From: Rabi Mishra Date: Tue, 9 Apr 2019 09:16:46 +0530 Subject: [PATCH] Fix grenade regression introduced by multicloud support Fixes grenade job regression introduced by commit 6990331639a96a7073f66a63c99f49d8f6c576b7. Change-Id: Ic2b782cd0a6e27c43d741ccf3864ecbcf543dc27 --- heat_integrationtests/prepare_test_env.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/heat_integrationtests/prepare_test_env.sh b/heat_integrationtests/prepare_test_env.sh index 636972205d..625f37a139 100755 --- a/heat_integrationtests/prepare_test_env.sh +++ b/heat_integrationtests/prepare_test_env.sh @@ -81,8 +81,8 @@ function _config_tempest_plugin iniset $conf_file heat_plugin boot_config_env $CONF_DEST/heat-templates/hot/software-config/boot-config/test_image_env.yaml # support test multi-cloud - openstack application credential create heat_multicloud --secret secret --unrestricted - app_cred_id=$(openstack application credential show heat_multicloud|grep ' id '|awk '{print $4}') + app_cred_id=$((openstack application credential show heat_multicloud || openstack application credential create heat_multicloud \ + --secret secret --unrestricted) | grep ' id '|awk '{print $4}') export OS_CREDENTIAL_SECRET_ID=$(openstack secret store -n heat-multi-cloud-test-cred --payload '{"auth_type": "v3applicationcredential", "auth": {"auth_url": $OS_AUTH_URL, "application_credential_id": $app_cred_id, "application_credential_secret": "secret"}, "roles": ["admin"], "project_id": $app_cred_project_id}') iniset $conf_file heat_features_enabled multi_cloud True iniset $conf_file heat_plugin heat_plugin credential_secret_id $OS_CREDENTIAL_SECRET_ID