|
|
|
@ -121,6 +121,7 @@ class fillVars(object, glob_attr):
|
|
|
|
|
mapInterface = {}
|
|
|
|
|
mapInterface["ip"] = ipaddr
|
|
|
|
|
mapInterface["cidr"] = str(ip.maskToCidr(mask)) if mask else ""
|
|
|
|
|
mapInterface["network"] = ip.getIpNet(ipaddr,mask=mask)
|
|
|
|
|
mapInterface["dhcp"] = "on" if dhcp else "off"
|
|
|
|
|
mapInterface["mac"] = mac
|
|
|
|
|
mapInterface["name"] = "{vendor} {name}".format(**pciInfo)
|
|
|
|
@ -1102,6 +1103,10 @@ class fillVars(object, glob_attr):
|
|
|
|
|
"""Current mask"""
|
|
|
|
|
return self.getAttributeFromHash('os_install_net_hash','cidr')
|
|
|
|
|
|
|
|
|
|
def get_os_install_net_network(self):
|
|
|
|
|
"""Current network"""
|
|
|
|
|
return self.getAttributeFromHash('os_install_net_hash','network')
|
|
|
|
|
|
|
|
|
|
def get_os_install_net_mac(self):
|
|
|
|
|
"""Current mac"""
|
|
|
|
|
return self.getAttributeFromHash('os_install_net_hash','mac')
|
|
|
|
|