summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark McLoughlin <markmc@redhat.com>2013-01-08 07:50:47 +0000
committerMark McLoughlin <markmc@redhat.com>2013-01-09 08:15:42 +0000
commit2803fd8d400b7d76138b2e2c152017a3d5e49685 (patch)
tree2c6f7e3847f4c83a8708d92e2e8551025664db7f
parent4c43371fd540f81320fb956266393a089e6d56dd (diff)
downloadnova-2803fd8d400b7d76138b2e2c152017a3d5e49685.tar.gz
nova-2803fd8d400b7d76138b2e2c152017a3d5e49685.tar.xz
nova-2803fd8d400b7d76138b2e2c152017a3d5e49685.zip
Move osapi_compute_unique_server_name_scope to db
This strange little option is only used within the DB layer. blueprint: scope-config-opts Change-Id: I10b0fef02a5fffd44094fe351cde683fc5c31442
-rw-r--r--nova/config.py5
-rw-r--r--nova/db/sqlalchemy/api.py8
2 files changed, 8 insertions, 5 deletions
diff --git a/nova/config.py b/nova/config.py
index 37f58b2f0..320e2e9bc 100644
--- a/nova/config.py
+++ b/nova/config.py
@@ -50,11 +50,6 @@ global_opts = [
cfg.ListOpt('enabled_apis',
default=['ec2', 'osapi_compute', 'metadata'],
help='a list of APIs to enable by default'),
- cfg.StrOpt('osapi_compute_unique_server_name_scope',
- default='',
- help='When set, compute API will consider duplicate hostnames '
- 'invalid within the specified scope, regardless of case. '
- 'Should be empty, "project" or "global".'),
cfg.StrOpt('default_instance_type',
default='m1.small',
help='default instance type to use, testing only'),
diff --git a/nova/db/sqlalchemy/api.py b/nova/db/sqlalchemy/api.py
index e7b9bfc75..66ecc8bf6 100644
--- a/nova/db/sqlalchemy/api.py
+++ b/nova/db/sqlalchemy/api.py
@@ -47,8 +47,16 @@ from nova.openstack.common import log as logging
from nova.openstack.common import timeutils
from nova.openstack.common import uuidutils
+db_opts = [
+ cfg.StrOpt('osapi_compute_unique_server_name_scope',
+ default='',
+ help='When set, compute API will consider duplicate hostnames '
+ 'invalid within the specified scope, regardless of case. '
+ 'Should be empty, "project" or "global".'),
+]
CONF = cfg.CONF
+CONF.register_opts(db_opts)
CONF.import_opt('compute_topic', 'nova.compute.rpcapi')
CONF.import_opt('sql_connection', 'nova.db.sqlalchemy.session')