class HammerCLIForemanKubevirt::ComputeResources::Kubevirt

Public Instance Methods

compute_attributes() click to toggle source
# File lib/hammer_cli_foreman_kubevirt/compute_resources/kubevirt.rb, line 10
def compute_attributes
  [
    ['cpu_cores', _('number of cores, Integer value')],
    ['memory', _('Amount of memory, integer value in bytes')]
  ]
end
host_attributes() click to toggle source
# File lib/hammer_cli_foreman_kubevirt/compute_resources/kubevirt.rb, line 17
def host_attributes
  [
    ['start', _('Boolean (expressed as 0 or 1), whether to start the machine or not')]
  ]
end
interface_attributes() click to toggle source
# File lib/hammer_cli_foreman_kubevirt/compute_resources/kubevirt.rb, line 23
def interface_attributes
  [
    ['compute_cni_provider', _('Container Network Interface Provider name')],
    ['compute_network', _('The network to connect the vm to')]
  ]
end
mandatory_resource_options() click to toggle source
Calls superclass method
# File lib/hammer_cli_foreman_kubevirt/compute_resources/kubevirt.rb, line 46
def mandatory_resource_options
  super + %i[hostname api_port namespace token]
end
name() click to toggle source
# File lib/hammer_cli_foreman_kubevirt/compute_resources/kubevirt.rb, line 6
def name
  _('KubeVirt')
end
provider_specific_fields() click to toggle source
# File lib/hammer_cli_foreman_kubevirt/compute_resources/kubevirt.rb, line 38
def provider_specific_fields
  [
      Fields::Field.new(:label => _('hostname'), :path => [:hostname]),
      Fields::Field.new(:label => _('api_port'), :path => [:api_port]),
      Fields::Field.new(:label => _('namespace'), :path => [:namespace]),
  ]
end
volume_attributes() click to toggle source
# File lib/hammer_cli_foreman_kubevirt/compute_resources/kubevirt.rb, line 30
def volume_attributes
  [
    ['capacity', _('Volume size in GB, integer value')],
    ['storage_class', _('Name of the storage class')],
    ['bootable', _('Boolean, only one volume can be bootable (overrides network interface boot)')]
  ]
end