Documentation
¶
Index ¶
- type Boot
- type CPU
- type Client
- type Config
- type Disk
- type Disks
- type Interface
- type InterfaceType
- type Interfaces
- type LegacyMonitor
- type Machine
- type MemMib
- type Module
- func (m *Module) Delete(name string) error
- func (m *Module) Exists(id string) bool
- func (m *Module) Inspect(name string) (pkg.VMInfo, error)
- func (m *Module) List() ([]string, error)
- func (m *Module) Logs(name string) (string, error)
- func (m *Module) Monitor(ctx context.Context)
- func (m *Module) Run(vm pkg.VM) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Boot ¶
type Boot struct {
Kernel string `json:"kernel_image_path"`
Initrd string `json:"initrd_path,omitempty"`
Args string `json:"boot_args"`
}
Boot config struct
type Client ¶ added in v0.5.0
type Client struct {
// contains filtered or unexported fields
}
Client to a cloud hypervisor instance
type Config ¶
type Config struct {
CPU CPU `json:"vcpu_count"`
Mem MemMib `json:"mem_size_mib"`
HTEnabled bool `json:"ht_enabled"`
}
Config struct
type Disk ¶ added in v0.5.0
type Disk struct {
ID string `json:"drive_id"`
Path string `json:"path_on_host"`
RootDevice bool `json:"is_root_device"`
ReadOnly bool `json:"is_read_only"`
}
Disk struct
type Interface ¶
type Interface struct {
ID string `json:"iface_id"`
Tap string `json:"host_dev_name"`
Mac string `json:"guest_mac,omitempty"`
}
Interface nic struct
type InterfaceType ¶ added in v0.5.0
type InterfaceType string
InterfaceType interface type
const ( // InterfaceTAP tuntap type InterfaceTAP InterfaceType = "tuntap" // InterfaceMACvTAP mactap type InterfaceMACvTAP InterfaceType = "macvtap" )
type Interfaces ¶ added in v0.5.0
type Interfaces []Interface
Interfaces is a list of node interfaces
type LegacyMonitor ¶ added in v0.5.0
type LegacyMonitor struct {
// contains filtered or unexported fields
}
LegacyMonitor has code to clean up legacy machines death
func (*LegacyMonitor) Monitor ¶ added in v0.5.0
func (m *LegacyMonitor) Monitor(ctx context.Context)
Monitor start vms monitoring
type Machine ¶
type Machine struct {
ID string `json:"id"`
Boot Boot `json:"boot-source"`
Disks Disks `json:"drives"`
Interfaces Interfaces `json:"network-interfaces"`
Config Config `json:"machine-config"`
// NoKeepAlive is not used by firecracker, but instead a marker
// for the vm mananger to not restart the machine when it stops
NoKeepAlive bool `json:"no-keep-alive"`
}
Machine struct
func MachineFromFile ¶ added in v0.5.0
MachineFromFile loads a vm config from file
type Module ¶ added in v0.4.9
type Module struct {
// contains filtered or unexported fields
}
Module implements the VMModule interface
func NewVMModule ¶
NewVMModule creates a new instance of vm manager
func (*Module) Exists ¶ added in v0.4.9
Exists checks if firecracker process running for this machine
Click to show internal directories.
Click to hide internal directories.