mirror of
https://github.com/puppetlabs/vmpooler.git
synced 2026-01-26 01:58:41 -05:00
Don't deploy VMs to not-good hypervisors
This implements a check to ensure that the VMware host being deployed to
is in a sane ('green') state.
This commit is contained in:
parent
36fffa381f
commit
ba5e713902
1 changed files with 4 additions and 2 deletions
|
|
@ -65,8 +65,10 @@ module Vmpooler
|
|||
datacenter.hostFolder.children.each do |folder|
|
||||
next unless folder.name == cluster
|
||||
folder.host.each do |host|
|
||||
hosts[host.name] = host
|
||||
hosts_sort[host.name] = host.vm.length
|
||||
if host.overallStatus == 'green'
|
||||
hosts[host.name] = host
|
||||
hosts_sort[host.name] = host.vm.length
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue