summaryrefslogtreecommitdiffstats
path: root/ci
diff options
context:
space:
mode:
authorNarinder Gupta <narinder.gupta@canonical.com>2017-07-14 12:53:26 -0500
committerNarinder Gupta <narinder.gupta@canonical.com>2017-07-14 13:13:51 -0500
commit5cad009f23edb842327ed1a33034b72b22da3114 (patch)
tree1a8bbab245015dcb0486b9b070311c187ebb14a6 /ci
parent67b1806b48566fb7ae2a897c3c3a43cc26a71c89 (diff)
modfied to use public IP for keystone.
Change-Id: Id0bcd86ee00b81de4e15722038e0e5e985772971 Signed-off-by: Narinder Gupta <narinder.gupta@canonical.com>
Diffstat (limited to 'ci')
-rwxr-xr-xci/openstack.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/ci/openstack.sh b/ci/openstack.sh
index 118be997..0a90b425 100755
--- a/ci/openstack.sh
+++ b/ci/openstack.sh
@@ -99,7 +99,9 @@ create_openrc() {
chmod 0600 ~/joid_config/admin-openrc
source ~/joid_config/admin-openrc
projectid=`openstack project show admin -c id -f value`
- configOpenrc admin $adminPasswd admin http://$keystoneIp:5000/v3 RegionOne publicURL $projectid > ~/joid_config/admin-openrcpublic
+ configOpenrc admin $adminPasswd admin http://$keystoneIp:5000/v3 RegionOne publicURL $projectid > ~/joid_config/admin-openrcinternal
+ urlapi=`openstack catalog show keystone --format yaml | python -c "import yaml; import sys; print yaml.load(sys.stdin)['endpoints']" | grep public | cut -d " " -f 4`
+ configOpenrc admin $adminPasswd admin $urlapi RegionOne publicURL $projectid > ~/joid_config/admin-openrc
else
configOpenrc2 admin $adminPasswd admin http://$keystoneIp:5000/v2.0 RegionOne > ~/joid_config/admin-openrc
chmod 0600 ~/joid_config/admin-openrc