To use this function add it to the class library file named InfobloxService.ts
GitHub Repository: https://github.com/SimonSparksUK/Orchestrator
Filename: InfobloxService.ts
Description: Orchestrator Function to add an Ipam Fixed Address in an Ipam Dhcp Range.
Function: IpamFixedAddressAddInIpamDhcpRange
public IpamFixedAddressAddInIpamDhcpRange(objIpamConnection: IpamConnection, objIpamDhcpRange: IpamDhcpRange, strIpAddress: string, astrMacAddress: string, strNetworkView: string, objIpamNetwork: IpamNetwork, strName: string, strComment: string, strMicrosoftDhcpServerIpAddress: string, blnRestartIfNeeded: boolean = false, arrIpamExtensibleAttribute?: IpamExtensibleAttribute[]): boolean {
let objIpamFixedAddressManager: IpamFixedAddressManager = objIpamConnection.getFixedAddressManager();
let objIpamFixedAddress: IpamFixedAddress = new IpamFixedAddress(strIpAddress, astrMacAddress, strNetworkView);
objIpamFixedAddress.name = strName;
objIpamFixedAddress.msServerIpAddress = strMicrosoftDhcpServerIpAddress;
objIpamFixedAddress.comment = strComment;
objIpamFixedAddress.restartIfNeeded = blnRestartIfNeeded;
if (arrIpamExtensibleAttribute) {
objIpamFixedAddress.extensibleAttributes = arrIpamExtensibleAttribute;
}
try {
objIpamFixedAddressManager.addFixedAddressInRange(objIpamFixedAddress, objIpamDhcpRange);
return true;
}
catch (objException) {
return false;
}
}Discover more from Cloud Build Tools
Subscribe to get the latest posts sent to your email.
