vm

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2024 License: Apache-2.0 Imports: 29 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

type Builder struct {
	// contains filtered or unexported fields
}

func NewBuilder

func NewBuilder(
	chBinary, jailerBinary, initBinary, linuxKernel string,
	images *images.Service,
	ctrd *client.Client,
	snapshotter string,
	cpuMhz int64,
	user User,
) (*Builder, error)

func (*Builder) BuildInstanceVM

func (b *Builder) BuildInstanceVM(ctx context.Context, instance *instance.Instance) (instance.VM, error)

BuildInstanceVM implements instance.VMBuilder.

func (*Builder) CleanupInstance

func (b *Builder) CleanupInstance(ctx context.Context, instance *instance.Instance) error

func (*Builder) CleanupInstanceVM

func (b *Builder) CleanupInstanceVM(ctx context.Context, instance *instance.Instance) error

CleanupInstanceVM implements instance.VMBuilder.

func (*Builder) RecoverInstanceVM

func (b *Builder) RecoverInstanceVM(ctx context.Context, i *instance.Instance) (instance.VM, error)

RecoverInstanceVM implements instance.VMBuilder.

type RunResult

type RunResult struct {
	HasBeenStopped bool
	VMExited       bool
	InitFailed     bool
	ProcessExited  bool
	ExitCode       *int64
	ExitedAt       time.Time
}

type User added in v0.2.0

type User struct {
	Uid int
	Gid int
}

Jump to

Keyboard shortcuts

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