I have created a new VI Role in the UI, and I add the URL I am following to define the privs in the Description field of the Role. The goal is to export the Role I created in the GUI so I can push the config to all my remaining vCenters. However, when I try to get the object in PowerCLI, I do not get the Description I entered:
Get-VIRole -Server $Global:DefaultVIServer -Name $VIRole | Select-Object Name,Description
Output shows the name of the Role for both objects rather than the Description I entered in the UI.
I can export the role/privs, they are created properly so I know the cmdlet I am using works, however I am still missing the Description field. I run a ForEach loop against the add-priviledge for each priv in my txt file, works like a champ, Description is doggin' me.
You are correct, the Description content that you see in the Web Client is not retrieved by the Get-VIRole cmdlet.
But this isn't a PowerCLI issue, when using the API directly, I'm seeing the same issue.
$roleName = 'TestRole'
$authMgr = Get-View AuthorizationManager
$authMgr.RoleList.Where{$_.Name -eq $roleName} |
Select Name,@{N='Description';E={$_.Info.Summary}}
This seems to be a vSphere issue.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
You are correct, the Description content that you see in the Web Client is not retrieved by the Get-VIRole cmdlet.
But this isn't a PowerCLI issue, when using the API directly, I'm seeing the same issue.
$roleName = 'TestRole'
$authMgr = Get-View AuthorizationManager
$authMgr.RoleList.Where{$_.Name -eq $roleName} |
Select Name,@{N='Description';E={$_.Info.Summary}}
This seems to be a vSphere issue.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
1) Thanks, I appreciate you taking the time to review this!
2) Thank you for validating this, I was frustrated that I was missing something
3) How/who can I raise this to, to get some eyes on it before the vSphere 8 release?
You could open an SR or contact your TAM
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference