diff options
author | Nikolas Hermanns <nikolas.hermanns@ericsson.com> | 2017-02-03 06:38:52 -0500 |
---|---|---|
committer | Nikolas Hermanns <nikolas.hermanns@ericsson.com> | 2017-02-06 12:16:10 -0500 |
commit | b8cad752ff9e3685c3b6490e7a4ef3a6862e3767 (patch) | |
tree | 6c19efb40538f4e26296b32a75f5aaecdd7384d9 /lib | |
parent | 8511e361a162afb961654a0aa47ea09ba4b55932 (diff) |
Fixing glance-client and rally
Since the project_id is not in the overcloudrc
glance clinet is failing.
Since os_tenant_name is not in overcloudrc
rally setup is failing.
Change-Id: Iaec4031d3419e8380fb8789288e587c44d600971
Signed-off-by: Nikolas Hermanns <nikolas.hermanns@ericsson.com>
Diffstat (limited to 'lib')
-rwxr-xr-x | lib/post-install-functions.sh | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/post-install-functions.sh b/lib/post-install-functions.sh index 51287c4b..55b4fe4d 100755 --- a/lib/post-install-functions.sh +++ b/lib/post-install-functions.sh @@ -148,6 +148,22 @@ if [ "${deploy_options_array['congress']}" == 'NeverTrue' ]; then echo "WARN: Datsource: doctor could NOT be created" fi fi + + +# Fix project_id and os_tenant_name not in overcloudrc +# Deprecated openstack client does not need project_id +# and os_tenant_name anymore but glance client and +# Rally in generall does need it. +# REMOVE when not needed in Rally/glance-client anymore. +if ! grep -q "OS_PROJECT_ID" ./overcloudrc;then + project_id=\$(openstack project list |grep admin|awk '{print \$2}') + echo "export OS_PROJECT_ID=\$project_id" >> ./overcloudrc +fi +if ! grep -q "OS_TENANT_NAME" ./overcloudrc;then + echo "export OS_TENANT_NAME=admin" >> ./overcloudrc +fi + + EOI # for virtual, we NAT external network through Undercloud |