Changeset 13883 in genesis


Ignore:
Timestamp:
May 27, 2017, 1:23:11 PM (8 years ago)
Author:
rick
Message:

Allow fixed addresses

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • nodes/Rustdam/wleiden.yaml

    r13844 r13883  
    7676  bridge_type: "NanoStation2"
    7777  status     : "up"
     78  dhcp_fixed :  [["e0:76:d0:3c:34:f0", "172.17.51.10", "camera-hooiberg"]]
    7879
    7980
  • tools/gformat.py

    r13863 r13883  
    583583         """ % { 'ifname' : ifname, 'mac' : mac, 'prefix': dhcp_part, 'fixed' : fixed }))
    584584      fixed += 1
     585
     586    if 'dhcp_fixed' in datadump[iface_key]:
     587      for (mac,addr,host) in datadump[iface_key]['dhcp_fixed']:
     588        dhcp_out[groupif].append(textwrap.dedent("""\
     589            host fixed-%(host)s {
     590              hardware ethernet %(mac)s;
     591              fixed-address %(addr)s;
     592            }
     593         """ % { 'host' : host, 'mac' : mac, 'addr' : addr}))
     594       
    585595
    586596    dhcp_out[groupif].append(textwrap.dedent("""\
Note: See TracChangeset for help on using the changeset viewer.