summaryrefslogtreecommitdiffstats
path: root/nova/api
diff options
context:
space:
mode:
authorVishvananda Ishaya <vishvananda@gmail.com>2012-08-12 10:01:09 -0700
committerVishvananda Ishaya <vishvananda@gmail.com>2012-08-12 10:08:47 -0700
commited80ed615762e0ff24235b7d57fa8b356c659e11 (patch)
tree70183b5340c7f5331c144329dac6ff73ea0116e7 /nova/api
parentd036fdbe0f8112e0345e80a08762e3c1bc7885f1 (diff)
Key auto_disk_config in create server off of ext.
Implements part of blueprint disable-server-extensions Makes sure that auto_disk_config is only accepted in the create server request if the extension is enabled. Note that the extension alias is OS-DCF because it also adds output to the server request. Change-Id: I59fafe769e1e562e6bf9f6db768acc9b0f8d2b93
Diffstat (limited to 'nova/api')
-rw-r--r--nova/api/openstack/compute/servers.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/nova/api/openstack/compute/servers.py b/nova/api/openstack/compute/servers.py
index ca446f24b..797c498b8 100644
--- a/nova/api/openstack/compute/servers.py
+++ b/nova/api/openstack/compute/servers.py
@@ -678,7 +678,9 @@ class Controller(wsgi.Controller):
if min_count > max_count:
min_count = max_count
- auto_disk_config = server_dict.get('auto_disk_config')
+ auto_disk_config = False
+ if self.ext_mgr.is_loaded('OS-DCF'):
+ auto_disk_config = server_dict.get('auto_disk_config')
scheduler_hints = {}
if self.ext_mgr.is_loaded('os-scheduler-hints'):