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 Address record using the Infoblox plugin
Function: AddRecordAddress
publicAddRecordAddress(objIpamConnection:IpamConnection,strFQDN:string,strIpSubnet:string,intCIDR:number,strDnsView:string="default",strNetworkView:string="default"):void{
letstrIPAddress:string=this.IpamNetworkGetNextAvailableIP(objIpamConnection,strIpSubnet,intCIDR);
letobjIpamAddressRecord:IpamAddressRecord=newIpamAddressRecord(strIPAddress,strFQDN,strDnsView);
try{
objIpamConnection.reconnect();
objIpamConnection.configDefaultNetworkView=strNetworkView;
objIpamConnection.configDefaultDnsView=strDnsView;
letobjIpamDnsRecordManager:IpamDnsRecordManager=objIpamConnection.getDnsRecordManager();
objIpamDnsRecordManager.addAddressRecord(objIpamAddressRecord);
}
catch (objException){
this.objLogger.info(objException);
}
}Discover more from Cloud Build Tools
Subscribe to get the latest posts sent to your email.
