mirror of https://github.com/docker/compose.git
Incorrect key name for IPAM options check
Signed-off-by: Joffrey F <joffrey@docker.com>
This commit is contained in:
parent
aa66338f39
commit
299ce6ad00
|
@ -169,7 +169,7 @@ def check_remote_ipam_config(remote, local):
|
|||
raise NetworkConfigChangedError(local.full_name, 'IPAM config aux_addresses')
|
||||
|
||||
remote_opts = remote_ipam.get('Options') or {}
|
||||
local_opts = local.ipam.get('options') or {}
|
||||
local_opts = local.ipam.get('Options') or {}
|
||||
for k in set.union(set(remote_opts.keys()), set(local_opts.keys())):
|
||||
if remote_opts.get(k) != local_opts.get(k):
|
||||
raise NetworkConfigChangedError(local.full_name, 'IPAM option "{}"'.format(k))
|
||||
|
|
|
@ -23,7 +23,10 @@ class NetworkTest(unittest.TestCase):
|
|||
'aux_addresses': ['11.0.0.1', '24.25.26.27'],
|
||||
'ip_range': '156.0.0.1-254'
|
||||
}
|
||||
]
|
||||
],
|
||||
'options': {
|
||||
'iface': 'eth0',
|
||||
}
|
||||
}
|
||||
labels = {
|
||||
'com.project.tests.istest': 'true',
|
||||
|
@ -57,6 +60,9 @@ class NetworkTest(unittest.TestCase):
|
|||
'Subnet': '172.0.0.1/16',
|
||||
'Gateway': '172.0.0.1'
|
||||
}],
|
||||
'Options': {
|
||||
'iface': 'eth0',
|
||||
},
|
||||
},
|
||||
'Labels': remote_labels
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue