Get-AteraAgent does not return expected value in environments that have replicated hostnames
ryancorrao opened this issue · 1 comments
Get-AteraAgent when run on "DC01" for example will return a list of objects that all have the same hostname. There is no way that I know of currently to get the specific device that you are currently working on without specifying the AgentID or CustomerID.
Is there a way that Get-AteraAgent does not have to default to using the hostname of the device but rather a unique identifier specific to the agent that PSAtera is running on?
$RawCompanyID = Get-ItemProperty -Path HKLM:\SOFTWARE\"ATERA Networks"\AlphaAgent -Name "CompanyId" $CompanyID = $RawCompanyID.CompanyId
suppose this gets the Customer/Company ID... I guess I've solved my own problem here... I do believe that Get-AteraAgent returning a list of Objects is not the intended functionality as mentioned in your comments in your code but it's not necessarily difficult to get around