summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNirmal Ranganathan <nirmal.ranganathan@rackspace.com>2011-05-16 11:12:16 -0500
committerNirmal Ranganathan <nirmal.ranganathan@rackspace.com>2011-05-16 11:12:16 -0500
commit262dec736fa6ef54a1101a0a17671ff2a19cbd95 (patch)
tree202c65a701e94b2990f3940ebc205f112f707446
parentd733eaf6749a5163165119ad164c817c3d7110b4 (diff)
downloadnova-262dec736fa6ef54a1101a0a17671ff2a19cbd95.tar.gz
nova-262dec736fa6ef54a1101a0a17671ff2a19cbd95.tar.xz
nova-262dec736fa6ef54a1101a0a17671ff2a19cbd95.zip
Added the imageRef and flavorRef attributes in the xml deserialization
-rw-r--r--nova/api/openstack/servers.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/nova/api/openstack/servers.py b/nova/api/openstack/servers.py
index 3cf78e32c..1289c1e0a 100644
--- a/nova/api/openstack/servers.py
+++ b/nova/api/openstack/servers.py
@@ -746,8 +746,9 @@ class ServerCreateRequestXMLDeserializer(object):
"""Marshal the server attribute of a parsed request"""
server = {}
server_node = self._find_first_child_named(node, 'server')
- for attr in ["name", "imageId", "flavorId"]:
- server[attr] = server_node.getAttribute(attr)
+ for attr in ["name", "imageId", "flavorId", "imageRef", "flavorRef"]:
+ if server_node.getAttribute(attr):
+ server[attr] = server_node.getAttribute(attr)
metadata = self._extract_metadata(server_node)
if metadata is not None:
server["metadata"] = metadata