Skip to content

Commit

Permalink
Porting bug fixes 1367208, 1374282 from R1.20 to R1.30.
Browse files Browse the repository at this point in the history
Fix bug 1367208
	neutronclient >= 2.3.7 requires public_endpoint and admin_endpoint in the keystone.conf,
	if not defaults to localhost.

Fix bug 1374282
Using CONTROLLER instead of locahost for glance and cinder endpoints.

Change-Id: I82d6f242161d7c25a8430826bbe01739370bbbc7
  • Loading branch information
cijohnson committed Oct 9, 2014
1 parent b84b7ba commit aa68646
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
12 changes: 6 additions & 6 deletions contrail_setup_utils/contrail-keystone-setup.sh
Expand Up @@ -220,9 +220,9 @@ fi
if [[ -n "$ENABLE_ENDPOINTS" ]]; then
if [ -z $(endpoint_lookup $GLANCE_SERVICE) ]; then
keystone endpoint-create --region RegionOne --service-id $GLANCE_SERVICE \
--publicurl http://localhost:9292/v1 \
--adminurl http://localhost:9292/v1 \
--internalurl http://localhost:9292/v1
--publicurl http://$CONTROLLER:9292/v1 \
--adminurl http://$CONTROLLER:9292/v1 \
--internalurl http://$CONTROLLER:9292/v1
fi
fi

Expand All @@ -248,9 +248,9 @@ fi
if [[ -n "$ENABLE_ENDPOINTS" ]]; then
if [ -z $(endpoint_lookup $CINDER_SERVICE) ]; then
keystone endpoint-create --region RegionOne --service-id $CINDER_SERVICE \
--publicurl 'http://localhost:8776/v1/$(tenant_id)s' \
--adminurl 'http://localhost:8776/v1/$(tenant_id)s' \
--internalurl 'http://localhost:8776/v1/$(tenant_id)s'
--publicurl 'http://'$CONTROLLER':8776/v1/$(tenant_id)s' \
--adminurl 'http://'$CONTROLLER':8776/v1/$(tenant_id)s' \
--internalurl 'http://'$CONTROLLER':8776/v1/$(tenant_id)s'
fi
fi

Expand Down
4 changes: 4 additions & 0 deletions contrail_setup_utils/keystone-server-setup.sh
Expand Up @@ -173,6 +173,8 @@ done
# Update all config files with service username and password
for svc in keystone; do
openstack-config --del /etc/$svc/$svc.conf database connection
openstack-config --set /etc/$svc/$svc.conf DEFAULT public_endpoint "http://$CONTROLLER:%(public_port)s/"
openstack-config --set /etc/$svc/$svc.conf DEFAULT admin_endpoint "http://$CONTROLLER:%(admin_port)s/"
openstack-config --set /etc/$svc/$svc.conf keystone_authtoken admin_tenant_name service
openstack-config --set /etc/$svc/$svc.conf keystone_authtoken admin_user $svc
openstack-config --set /etc/$svc/$svc.conf keystone_authtoken admin_password $SERVICE_PASSWORD
Expand All @@ -194,6 +196,8 @@ fi

if [ "$INTERNAL_VIP" != "none" ]; then
# Openstack HA specific config
openstack-config --set /etc/keystone/keystone.conf DEFAULT public_endpoint "http://$CONTROLLER:%(public_port)s/"
openstack-config --set /etc/keystone/keystone.conf DEFAULT admin_endpoint "http://$CONTROLLER:%(admin_port)s/"
openstack-config --set /etc/keystone/keystone.conf sql connection mysql://keystone:keystone@$CONTROLLER:3306/keystone
openstack-config --set /etc/keystone/keystone.conf token driver keystone.token.backends.sql.Token
openstack-config --del /etc/keystone/keystone.conf memcache servers
Expand Down

0 comments on commit aa68646

Please sign in to comment.