bundle/dhcpd: improvements #19
1 changed files with 3 additions and 2 deletions
|
@ -14,9 +14,10 @@ def get_static_allocations(metadata):
|
||||||
for identifier, interface in rnode.metadata.get('interfaces', {}).items():
|
for identifier, interface in rnode.metadata.get('interfaces', {}).items():
|
||||||
if interface.get('dhcp', False):
|
if interface.get('dhcp', False):
|
||||||
allocations[rnode.name] = {
|
allocations[rnode.name] = {
|
||||||
'ipv4': sorted(interface['ips'])[0],
|
'ipv4': sorted(interface['ips'])[0],
|
||||||
'mac': interface['mac'],
|
'mac': interface['mac'],
|
||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
'dhcpd': {
|
'dhcpd': {
|
||||||
'fixed_allocations': allocations,
|
'fixed_allocations': allocations,
|
||||||
|
|
Loading…
Reference in a new issue