mirror of
https://github.com/puppetlabs/vmfloaty.git
synced 2026-01-26 05:28:40 -05:00
Update CLI commands and docs
This commit is contained in:
parent
55d4046c75
commit
b14fdc6219
1 changed files with 10 additions and 6 deletions
|
|
@ -2,7 +2,7 @@ require 'thor'
|
||||||
require 'net/http'
|
require 'net/http'
|
||||||
|
|
||||||
class CLI < Thor
|
class CLI < Thor
|
||||||
desc "get [operating system,...] [--withpe]", "Gets a VM"
|
desc "get <OPERATING SYSTEM,...> [--withpe]", "Gets a VM"
|
||||||
option :withpe
|
option :withpe
|
||||||
def get(os)
|
def get(os)
|
||||||
say "vmpooler: #{@vmpooler_url}"
|
say "vmpooler: #{@vmpooler_url}"
|
||||||
|
|
@ -13,7 +13,7 @@ class CLI < Thor
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
desc "modify [hostname]", "Modify a VM"
|
desc "modify <HOSTNAME>", "Modify a VM"
|
||||||
def modify(hostname)
|
def modify(hostname)
|
||||||
say 'Modify a vm'
|
say 'Modify a vm'
|
||||||
end
|
end
|
||||||
|
|
@ -23,12 +23,16 @@ class CLI < Thor
|
||||||
say 'List of active VMs'
|
say 'List of active VMs'
|
||||||
end
|
end
|
||||||
|
|
||||||
desc "list", "List all open VMs"
|
desc "list [PATTERN]", "List all open VMs"
|
||||||
def list
|
def list(pattern=nil)
|
||||||
|
if pattern
|
||||||
|
say "Filtering VMs based on #{pattern}"
|
||||||
|
else
|
||||||
say 'Listing open vms on vmpooler'
|
say 'Listing open vms on vmpooler'
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
desc "release [hostname]", "Schedules a VM for deletion"
|
desc "release <HOSTNAME>", "Schedules a VM for deletion"
|
||||||
def release(hostname)
|
def release(hostname)
|
||||||
say 'Releases a VM'
|
say 'Releases a VM'
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue