summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVishvananda Ishaya <vishvananda@gmail.com>2011-07-26 21:29:24 +0000
committerVishvananda Ishaya <vishvananda@gmail.com>2011-07-26 21:29:24 +0000
commit5c812bbdc15e0cf974026fcfaacd54e7a9f144cc (patch)
tree51c2d7223d59dd9ef9456081440c164e459e503c
parentcb631be09c36d29ddb6e89a647c5161bc43c4aa7 (diff)
downloadnova-5c812bbdc15e0cf974026fcfaacd54e7a9f144cc.tar.gz
nova-5c812bbdc15e0cf974026fcfaacd54e7a9f144cc.tar.xz
nova-5c812bbdc15e0cf974026fcfaacd54e7a9f144cc.zip
cherry-pick tr3buchet's fix for milestone branch
-rw-r--r--nova/compute/manager.py2
-rw-r--r--nova/network/api.py3
2 files changed, 3 insertions, 2 deletions
diff --git a/nova/compute/manager.py b/nova/compute/manager.py
index 31627fe3b..893c18aef 100644
--- a/nova/compute/manager.py
+++ b/nova/compute/manager.py
@@ -868,7 +868,7 @@ class ComputeManager(manager.SchedulerDependentManager):
"""
self.network_api.add_fixed_ip_to_instance(context, instance_id,
- network_id)
+ self.host, network_id)
self.inject_network_info(context, instance_id)
self.reset_network(context, instance_id)
diff --git a/nova/network/api.py b/nova/network/api.py
index 33a9fe239..247768722 100644
--- a/nova/network/api.py
+++ b/nova/network/api.py
@@ -164,9 +164,10 @@ class API(base.Base):
{'method': 'deallocate_for_instance',
'args': args})
- def add_fixed_ip_to_instance(self, context, instance_id, network_id):
+ def add_fixed_ip_to_instance(self, context, instance_id, host, network_id):
"""Adds a fixed ip to instance from specified network."""
args = {'instance_id': instance_id,
+ 'host': host,
'network_id': network_id}
rpc.cast(context, FLAGS.network_topic,
{'method': 'add_fixed_ip_to_instance',