mirror of
https://github.com/puppetlabs/vmpooler.git
synced 2026-01-26 10:08:40 -05:00
Merge branch 'master' of github.com:sschneid/vmware-host-pooler
This commit is contained in:
commit
2dd4d4bb21
1 changed files with 9 additions and 13 deletions
|
|
@ -142,9 +142,6 @@ post '/vm/:template' do
|
|||
result = {}
|
||||
result[params[:template]] = {}
|
||||
|
||||
if ( ( ! params[:folder] ) or ( ! params[:pool] ))
|
||||
result[params[:template]]['error'] = 'You must specify a destination \'folder\' and \'pool\''
|
||||
else
|
||||
if ( $redis.scard('vmware_host_pool__ready__'+params[:template]) > 0 )
|
||||
vm = $redis.spop('vmware_host_pool__ready__'+params[:template])
|
||||
|
||||
|
|
@ -160,7 +157,6 @@ post '/vm/:template' do
|
|||
else
|
||||
result[params[:template]]['ok'] = false
|
||||
end
|
||||
end
|
||||
|
||||
JSON.pretty_generate(result)
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue