Configure nova.flags as well as openstack.common.cfg

Because we are using nova classes directly (Service, Manager, etc.)
we need to initialize the configuration modules that those
classes use.

Change-Id: Idafd4a8346fc59332114ea7536893470bf9eaff8
This commit is contained in:
Doug Hellmann 2012-06-26 15:25:12 -04:00
parent 1b7b651d86
commit 8232832bba

View File

@ -17,6 +17,8 @@
# License for the specific language governing permissions and limitations
# under the License.
from nova import flags
from ceilometer import log
from ceilometer.openstack.common import cfg
@ -29,4 +31,9 @@ cfg.CONF.register_opts([
def prepare_service(argv=[]):
cfg.CONF(argv[1:])
# FIXME(dhellmann): We must set up the nova.flags module in order
# to have the RPC and DB access work correctly because we are
# still using the Service object out of nova directly. We need to
# move that into openstack.common.
flags.FLAGS(argv[1:])
log.setup()