Merge "container driver: log network id as network id"

This commit is contained in:
Jenkins 2017-02-21 01:33:37 +00:00 committed by Gerrit Code Review
commit 767be0a8b9
2 changed files with 4 additions and 1 deletions

View File

@ -235,6 +235,7 @@ class ContainerShareDriver(driver.ShareDriver, driver.ExecuteMixin):
'lb': self.configuration.container_linux_bridge_name, 'lb': self.configuration.container_linux_bridge_name,
'ovsb': self.configuration.container_ovs_bridge_name, 'ovsb': self.configuration.container_ovs_bridge_name,
'ip': port_address, 'ip': port_address,
'network': network_info['neutron_net_id'],
'subnet': network_info['neutron_subnet_id'], 'subnet': network_info['neutron_subnet_id'],
} }
LOG.debug("Container %(id)s veth is %(veth)s.", msg_helper) LOG.debug("Container %(id)s veth is %(veth)s.", msg_helper)
@ -254,7 +255,8 @@ class ContainerShareDriver(driver.ShareDriver, driver.ExecuteMixin):
self.configuration.container_ovs_bridge_name, host_veth, self.configuration.container_ovs_bridge_name, host_veth,
*(e_mac + e_id + e_status + e_mcid), run_as_root=True) *(e_mac + e_id + e_status + e_mcid), run_as_root=True)
LOG.debug("Now container %(id)s should be accessible from network " LOG.debug("Now container %(id)s should be accessible from network "
"%(subnet)s by address %(ip)s." % msg_helper) "%(network)s and subnet %(subnet)s by address %(ip)s." %
msg_helper)
@utils.synchronized("container_driver_teardown_lock", external=True) @utils.synchronized("container_driver_teardown_lock", external=True)
def _teardown_server(self, *args, **kwargs): def _teardown_server(self, *args, **kwargs):

View File

@ -50,6 +50,7 @@ def fake_network(**kwargs):
'id': 'fake_network_id', 'id': 'fake_network_id',
'server_id': 'fake_server_id', 'server_id': 'fake_server_id',
'network_allocations': [allocations], 'network_allocations': [allocations],
'neutron_net_id': 'fake_net',
'neutron_subnet_id': 'fake_subnet', 'neutron_subnet_id': 'fake_subnet',
} }
network.update(kwargs) network.update(kwargs)