class Fog::Proxmox::Compute::Disk

class Disk model: pve.proxmox.com/pve-docs/api-viewer/index.html#/nodes/{node}/{qemu|lxc}/{vmid}/config size is in Gb

Public Instance Methods

cdrom?() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 52
def cdrom?
  id == 'ide2' && media == 'cdrom'
end
cloud_init?() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 68
def cloud_init?
  id != 'ide2' && media == 'cdrom'
end
controller() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 44
def controller
  Fog::Proxmox::DiskHelper.extract_controller(id)
end
controller?() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 64
def controller?
  Fog::Proxmox::DiskHelper.server_disk?(id)
end
device() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 48
def device
  Fog::Proxmox::DiskHelper.extract_device(id)
end
flatten() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 80
def flatten
  Fog::Proxmox::DiskHelper.flatten(attributes)
end
hard_disk?() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 72
def hard_disk?
  controller? && !cdrom? && !cloud_init?
end
has_volume?() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 88
def has_volume?
  !volid.empty?
end
mount_point?() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 60
def mount_point?
  Fog::Proxmox::DiskHelper.mount_point?(id)
end
rootfs?() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 56
def rootfs?
  id == 'rootfs'
end
template?() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 76
def template?
  Fog::Proxmox::DiskHelper.template?(volid)
end
to_s() click to toggle source
# File lib/fog/proxmox/compute/models/disk.rb, line 84
def to_s
  Fog::Proxmox::Hash.flatten(flatten)
end