Merge "Hot-fix: do not share Admin interface w/ any net"
This commit is contained in:
commit
a88ce37dc1
@ -15,7 +15,8 @@
|
||||
"render_addr_mask": null,
|
||||
"map_priority": 0,
|
||||
"unmovable": true,
|
||||
"assign_vip": false
|
||||
"assign_vip": false,
|
||||
"dedicated_nic": true
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -497,7 +497,7 @@ class TestNeutronManager(BaseIntegrationTest):
|
||||
other_nic, empty_nic = None, None
|
||||
for nic in other_nics:
|
||||
names = [n.name for n in nic.assigned_networks_list]
|
||||
if names == ['public']:
|
||||
if 'public' in names:
|
||||
other_nic = nic
|
||||
other_nets = names
|
||||
elif names == []:
|
||||
|
@ -185,7 +185,6 @@ class TestNovaHandlers(TestNetworkChecking):
|
||||
'interfaces. Affected:\n',
|
||||
task['message'])
|
||||
self.assertIn('"management"', task['message'])
|
||||
self.assertIn('"admin (PXE)"', task['message'])
|
||||
self.assertIn(' networks at node "Untitled', task['message'])
|
||||
|
||||
def test_network_checking_fails_if_networks_cidr_range_intersection(self):
|
||||
|
@ -202,10 +202,10 @@ class TestNodeHandlers(BaseIntegrationTest):
|
||||
headers=self.default_headers)
|
||||
self.assertEquals(resp.status, 200)
|
||||
response = json.loads(resp.body)
|
||||
net_name_per_nic = [['fuelweb_admin', 'storage', 'fixed'],
|
||||
['public', 'floating'],
|
||||
net_name_per_nic = [['fuelweb_admin'],
|
||||
['public', 'floating', 'storage', 'fixed'],
|
||||
['management']]
|
||||
for i, nic in enumerate(response):
|
||||
for i, nic in enumerate(sorted(response, key=lambda x: x['name'])):
|
||||
net_names = set([net['name'] for net in nic['assigned_networks']])
|
||||
self.assertEqual(set(net_name_per_nic[i]), net_names)
|
||||
|
||||
@ -239,10 +239,11 @@ class TestNodeHandlers(BaseIntegrationTest):
|
||||
headers=self.default_headers)
|
||||
self.assertEquals(resp.status, 200)
|
||||
response = json.loads(resp.body)
|
||||
net_name_per_nic = [['fuelweb_admin', 'storage', 'fixed',
|
||||
'public', 'floating', 'management'],
|
||||
[], []]
|
||||
for i, nic in enumerate(response):
|
||||
net_name_per_nic = [['fuelweb_admin'],
|
||||
['storage', 'fixed', 'public', 'floating',
|
||||
'management'],
|
||||
[]]
|
||||
for i, nic in enumerate(sorted(response, key=lambda x: x['name'])):
|
||||
net_names = set([net['name'] for net in nic['assigned_networks']])
|
||||
self.assertEqual(set(net_name_per_nic[i]), net_names)
|
||||
|
||||
@ -280,10 +281,10 @@ class TestNodeHandlers(BaseIntegrationTest):
|
||||
headers=self.default_headers)
|
||||
self.assertEquals(resp.status, 200)
|
||||
response = json.loads(resp.body)
|
||||
net_name_per_nic = [['fuelweb_admin', 'storage', 'private'],
|
||||
['public'],
|
||||
net_name_per_nic = [['fuelweb_admin'],
|
||||
['public', 'storage', 'private'],
|
||||
['management']]
|
||||
for i, nic in enumerate(response):
|
||||
for i, nic in enumerate(sorted(response, key=lambda x: x['name'])):
|
||||
net_names = set([net['name'] for net in nic['assigned_networks']])
|
||||
self.assertEqual(set(net_name_per_nic[i]), net_names)
|
||||
|
||||
@ -317,10 +318,10 @@ class TestNodeHandlers(BaseIntegrationTest):
|
||||
headers=self.default_headers)
|
||||
self.assertEquals(resp.status, 200)
|
||||
response = json.loads(resp.body)
|
||||
net_name_per_nic = [['fuelweb_admin', 'storage', 'public',
|
||||
'management', 'private'],
|
||||
[], []]
|
||||
for i, nic in enumerate(response):
|
||||
net_name_per_nic = [['fuelweb_admin'],
|
||||
['storage', 'public', 'management', 'private'],
|
||||
[]]
|
||||
for i, nic in enumerate(sorted(response, key=lambda x: x['name'])):
|
||||
net_names = set([net['name'] for net in nic['assigned_networks']])
|
||||
self.assertEqual(set(net_name_per_nic[i]), net_names)
|
||||
|
||||
|
@ -130,11 +130,7 @@ class TestVerifyNetworkTaskManagers(BaseIntegrationTest):
|
||||
task.message
|
||||
)
|
||||
for n in self.env.nodes:
|
||||
self.assertIn(
|
||||
'"admin (PXE)", "storage" networks '
|
||||
'at node "{0}"'.format(n.name),
|
||||
task.message
|
||||
)
|
||||
self.assertIn('"storage"', task.message)
|
||||
self.assertEquals(mocked_rpc.called, False)
|
||||
|
||||
@fake_tasks()
|
||||
|
Loading…
Reference in New Issue
Block a user