keystone config file doesn't work if you specify admin_endpoint

Bug #1160573 reported by Sean Dague
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Identity (keystone)
Fix Released
Medium
Dolph Mathews

Bug Description

If you uncomment the following 2 lines in /etc/keystone.conf:

# The port number which the public admin listens on
admin_port = 35357

# The base endpoint URLs for keystone that are advertised to clients
# (NOTE: this does NOT affect how keystone listens for connections)
# public_endpoint = http://localhost:%(public_port)d/
admin_endpoint = http://localhost:%(admin_port)d/

Then try to start keystone you'll get:

(keystone-all): 2013-03-26 16:14:52,754 DEBUG cfg log_opt_values ********************************************************************************
Traceback (most recent call last):
  File "/opt/stack/grizzly/keystone/bin/keystone-all", line 112, in <module>
    options = deploy.appconfig('config:%s' % paste_config)
  File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", line 261, in appconfig
    global_conf=global_conf)
  File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", line 296, in loadcontext
    global_conf=global_conf)
  File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", line 320, in _loadconfig
    return loader.get_context(object_type, name, global_conf)
  File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", line 413, in get_context
    defaults = self.parser.defaults()
  File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", line 68, in defaults
    defaults[key] = self.get('DEFAULT', key) or val
  File "/usr/lib/python2.7/ConfigParser.py", line 623, in get
    return self._interpolate(section, option, value, d)
  File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", line 75, in _interpolate
    self, section, option, rawval, vars)
  File "/usr/lib/python2.7/ConfigParser.py", line 666, in _interpolate
    value = value % vars
TypeError: Error in file /etc/keystone/keystone.conf: %d format: a number is required, not str

It appears that config parser doesn't actually support %d in interpolation

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to keystone (master)

Fix proposed to branch: master
Review: https://review.openstack.org/25452

Changed in keystone:
assignee: nobody → Dolph Mathews (dolph)
status: New → In Progress
Dolph Mathews (dolph)
Changed in keystone:
importance: Undecided → Medium
tags: added: grizzly-backport-potential
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to keystone (master)

Reviewed: https://review.openstack.org/25452
Committed: http://github.com/openstack/keystone/commit/b94f62a67b90ba030c38b2770e3f96ba1b155c55
Submitter: Jenkins
Branch: master

commit b94f62a67b90ba030c38b2770e3f96ba1b155c55
Author: Dolph Mathews <email address hidden>
Date: Tue Mar 26 17:34:03 2013 -0500

    Use string for port in default endpoints (bug 1160573)

    Change-Id: I940f331eee14e449333e5d0ba5d071836a496653

Changed in keystone:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in keystone:
milestone: none → havana-1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in keystone:
milestone: havana-1 → 2013.2
Alan Pevec (apevec)
tags: removed: grizzly-backport-potential
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.