runner

package
v0.0.18 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 16, 2024 License: Apache-2.0 Imports: 8 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildQemuArgs added in v0.0.18

func BuildQemuArgs(log *logrus.Logger, rcnf *RunConf) ([]string, error)

func StartQemu added in v0.0.18

func StartQemu(rcnf RunConf) error

Types

type PortForward

type PortForward struct {
	HostPort int
	VMPort   int
	Protocol string
}

type PortForwards

type PortForwards []PortForward

func ParsePortForward

func ParsePortForward(flags []string) (PortForwards, error)

func (PortForwards) QemuArgs

func (pf PortForwards) QemuArgs() []string

type RunConf added in v0.0.18

type RunConf struct {
	// Image filename
	Image string
	// kernel filename to boot with. (if empty no -kernel option will be passed to qemu)
	KernelFname string
	// kernel append args to add when a kernel is passed to qemu
	KernelAppendArgs []string
	// Do not run the qemu command, just print it
	QemuPrint bool
	// Do not use KVM acceleration, even if /dev/kvm exists
	DisableKVM bool
	// Daemonize QEMU after initializing
	Daemonize bool
	// Log file for virtual console output
	ConsoleLogFile string

	// Print qemu command before running it
	Verbose bool

	// Disable the network connection to the VM
	DisableNetwork bool
	ForwardedPorts PortForwards

	Logger *logrus.Logger

	HostMount string

	SerialPort int

	CPU int
	Mem string
	// Kind of CPU to use (e.g. host or kvm64)
	CPUKind string

	// RootDev is the type of device used for the root fs. Can be "hda" or "vda"
	RootDev string

	QemuMonitorPort int
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL