You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my Project i ran Get-Help New-nbVirtualMachine -Full to see how i create a VirtualMachine Object
Example says:
PS C:\>$lookup = @{
device_type='dcim/device-types'
device_role='dcim/device-roles'
site='organization/sites'
status='dcim/_choices'
}
$VirtualMachine = @{
name = 'example'
serial = 'aka123457'
device_type = 'dl380-g9'
device_role = 'oracle'
site = 'chicago'
status = 'active'
}
New-nbVirtualMachine -lookup $lookup -object $VirtualMachine
So i did. I created a HashTable describing my virtual Machine and got errors back.
After reviewing your code i saw that it expects a PowershellObject and NOT a HashTable.
So i ended up with something like this to get it work:
In my Project i ran
Get-Help New-nbVirtualMachine -Full
to see how i create a VirtualMachine ObjectExample says:
So i did. I created a HashTable describing my virtual Machine and got errors back.
After reviewing your code i saw that it expects a PowershellObject and NOT a HashTable.
So i ended up with something like this to get it work:
$nbVMCluster=Get-nbCluster -Query @{name=($o_vm | Get-Cluster).Name}
I think documentation should be edited here to avoiid misleading Cmdlet Users
The text was updated successfully, but these errors were encountered: