Open daydrim opened 5 years ago
Right now I am working around this with vcd search vm
. Should this be the same output?
I'm amazed vcd search vm
returns data @coffeejoshua. When I execute it, vcd only reports not found
as output.
When I use a VM name (exact or wildcard) an extra argument
error message is displayed.
vcd search vm my-vm
Usage: vcd search [OPTIONS] [resource-type]
Try "vcd search -h" for help.
Error: Got unexpected extra argument (my-vm)
Not having the ability to list VMs is a great annoyance. I hope this will get fixed soon.
2 years... this problem still not resolve...
Any update?
As an end-user, just installed vcd-cli first time to list VMs and hit this issue. $ vcd vm list
was my first command.
Any updates on this? How can I list VMs in simple manner? If I can not list VMs this way, I think the only way is to use web dashboard. It would be great to prioritize this issue.
cc @pacogomez @kkkothari
Just went through a similar experience. Initially I thought I could just vcd vapp list
but not all VMs I have are in a vApp. Eventually I managed to workaround not having vcd vm list
like that:
vcd search vm -f 'isVAppTemplate==false'
This lists all VM objects that are not vApp templates. Looks like -f
accepts multiple filters so one can have something like that too:
vcd search vm -f 'numberOfCpus=gt=0;isVAppTemplate==false'
which also filters just those with more than 0 CPUs which are again practically all. I hope this will be useful to whoever else comes to this issue. Note that when you get some output from this you can use the names of the columns as filters in case you need to craft something a bit more special for your use case.
function in vm.py:
def list_vms(ctx):
still returns:raise Exception('not implemented')
Expected behavior: Funtion returns list of all vms in the vDC