vmm

package
v0.0.0-...-f6323ea Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2024 License: AGPL-3.0 Imports: 28 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RunCMD

func RunCMD() *cobra.Command

Types

type PodNetwork

type PodNetwork struct {
	GuestMac    net.HardwareAddr
	GuestIfname string
	CID         uint32
}

type VM

type VM struct {
	ID      string
	WorkDir string

	Launch spec.Launch

	CradleGuest spec.Cradle

	// qemu
	Cmd *exec.Cmd

	// virtiofsd
	Filesystems []*exec.Cmd

	// sdn
	EthHostSideMac  [6]byte
	EthHostSideName string
	Ip4             *net.IPNet
	Ip6             *net.IPNet
	Gw4             net.IP
	Gw6             net.IP

	// reporter keepalive
	Stage atomic.Uint32

	PodNetwork *PodNetwork
	// contains filtered or unexported fields
}

func (*VM) Cleanup

func (self *VM) Cleanup()

func (*VM) DownloadImage

func (self *VM) DownloadImage(
	ctx context.Context,
	strref string,
	auth string,
) (*spec.Container, error)

func (*VM) KillFilesystems

func (self *VM) KillFilesystems()

func (*VM) KillQemu

func (self *VM) KillQemu()

func (*VM) LaunchQemu

func (self *VM) LaunchQemu() (err error)

func (*VM) MakeGuestLaunchConfig

func (self *VM) MakeGuestLaunchConfig() (err error)

func (*VM) PrepareCradleGuest

func (self *VM) PrepareCradleGuest(cradlePath string) (err error)

func (*VM) SetupNetworkPostLaunch

func (self *VM) SetupNetworkPostLaunch() error

func (*VM) SetupWorkDir

func (self *VM) SetupWorkDir() error

func (*VM) StartFilesystems

func (self *VM) StartFilesystems() error

func (*VM) StartNetwork

func (self *VM) StartNetwork() error

func (*VM) StartVDocker

func (self *VM) StartVDocker() error

func (*VM) StopNetwork

func (self *VM) StopNetwork()

func (*VM) Wait

func (self *VM) Wait() error

Jump to

Keyboard shortcuts

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