1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00
This commit is contained in:
Vitaliy Okulov 2015-05-10 14:43:36 +00:00
parent ad9981f565
commit 31b0ffafa8

View file

@ -1836,7 +1836,7 @@ class LinuxNetwork(Network):
if words[0] == 'inet': if words[0] == 'inet':
if '/' in words[1]: if '/' in words[1]:
address, netmask_length = words[1].split('/') address, netmask_length = words[1].split('/')
broadcast = words[3] broadcast = words[3]
else: else:
# pointopoint interfaces do not have a prefix # pointopoint interfaces do not have a prefix
address = words[1] address = words[1]
@ -1850,7 +1850,7 @@ class LinuxNetwork(Network):
interfaces[iface] = {} interfaces[iface] = {}
if not secondary and "ipv4" not in interfaces[iface]: if not secondary and "ipv4" not in interfaces[iface]:
interfaces[iface]['ipv4'] = {'address': address, interfaces[iface]['ipv4'] = {'address': address,
'broadcast': broadcast, 'broadcast': broadcast,
'netmask': netmask, 'netmask': netmask,
'network': network} 'network': network}
else: else:
@ -1858,7 +1858,7 @@ class LinuxNetwork(Network):
interfaces[iface]["ipv4_secondaries"] = [] interfaces[iface]["ipv4_secondaries"] = []
interfaces[iface]["ipv4_secondaries"].append({ interfaces[iface]["ipv4_secondaries"].append({
'address': address, 'address': address,
'broadcast': broadcast, 'broadcast': broadcast,
'netmask': netmask, 'netmask': netmask,
'network': network, 'network': network,
}) })
@ -1869,7 +1869,7 @@ class LinuxNetwork(Network):
interfaces[device]["ipv4_secondaries"] = [] interfaces[device]["ipv4_secondaries"] = []
interfaces[device]["ipv4_secondaries"].append({ interfaces[device]["ipv4_secondaries"].append({
'address': address, 'address': address,
'broadcast': broadcast, 'broadcast': broadcast,
'netmask': netmask, 'netmask': netmask,
'network': network, 'network': network,
}) })