A generic ‘hypervisor’ resource to define an individual hypervisor, for example, a hypervisor zone from an OnApp CP, or a more generic interface such as to RackSpace OpenStack or EC2. Any resource always has credentials which are used to authenticate when a VM is created by the market on this ‘hypervisor’ resource.
Is backup of VMs supported?
Number of cpus available
Hash of credentials required to provision a VM (likely specific to a hypervisor)
Total storage size
Total hypervisor memory
Create a new ‘hypervisor’ resource with given credentials
hash - Hash of attributes to apply
type - type for serialization help
# File lib/onapp_market/resource/compute.rb, line 28 def initialize(hash = {}, type = nil) type = TYPE if type == nil super(hash, type) restrict :credentials, [:supplier, :admin, :ro_admin] end
Get the flavors supported by this compute resource
OnappMarket::API::Response, data contains array of flavors if successful
# File lib/onapp_market/resource/compute.rb, line 38 def get_flavors @api.get("/compute/#{self.resource_id}/flavors") end