Merge "Clean port dns_name in case of port detach"
This commit is contained in:
commit
e1522c1d86
@ -315,7 +315,8 @@ class API(base_api.NetworkAPI):
|
|||||||
# in case the caller forgot to filter the list.
|
# in case the caller forgot to filter the list.
|
||||||
if port_id is None:
|
if port_id is None:
|
||||||
continue
|
continue
|
||||||
port_req_body = {'port': {'device_id': '', 'device_owner': ''}}
|
port_req_body = {'port': {'device_id': '', 'device_owner': '',
|
||||||
|
'dns_name': ''}}
|
||||||
if port_binding:
|
if port_binding:
|
||||||
port_req_body['port']['binding:host_id'] = None
|
port_req_body['port']['binding:host_id'] = None
|
||||||
port_req_body['port']['binding:profile'] = {}
|
port_req_body['port']['binding:profile'] = {}
|
||||||
|
@ -3545,7 +3545,7 @@ class TestNeutronv2WithMock(test.TestCase):
|
|||||||
api = neutronapi.API()
|
api = neutronapi.API()
|
||||||
api._unbind_ports(mock_ctx, ports, mock_client)
|
api._unbind_ports(mock_ctx, ports, mock_client)
|
||||||
|
|
||||||
body = {'port': {'device_id': '', 'device_owner': ''}}
|
body = {'port': {'device_id': '', 'device_owner': '', 'dns_name': ''}}
|
||||||
if has_ext:
|
if has_ext:
|
||||||
body['port']['binding:host_id'] = None
|
body['port']['binding:host_id'] = None
|
||||||
body['port']['binding:profile'] = {}
|
body['port']['binding:profile'] = {}
|
||||||
|
Loading…
Reference in New Issue
Block a user