mirror of
https://github.com/puppetlabs/vmfloaty.git
synced 2026-01-26 05:28:40 -05:00
Filter list command
This commit is contained in:
parent
b9c43f9695
commit
85d5eda24b
1 changed files with 3 additions and 2 deletions
|
|
@ -35,11 +35,12 @@ class CLI < Thor
|
|||
|
||||
if pattern
|
||||
# Filtering VMs based on pattern
|
||||
hosts = host_res.select { |i| i[/#{pattern}/] }
|
||||
else
|
||||
# list all vms
|
||||
hosts = host_res
|
||||
end
|
||||
|
||||
puts host_res
|
||||
puts hosts
|
||||
end
|
||||
|
||||
desc "release <HOSTNAME>", "Schedules a VM for deletion"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue