oci

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2020 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Runtime

type Runtime interface {
	CreateContainer(
		id container.ID,
		bundleDir string,
		logfile string,
		exitfile string,
		attachfile string,
		stdin bool,
		stdinOnce bool,
		timeout time.Duration,
	) (pid int, err error)
	StartContainer(id container.ID) error
	KillContainer(id container.ID, sig os.Signal) error
	DeleteContainer(id container.ID) error
	ContainerState(container.ID) (StateResp, error)
}

Runtime represents an OCI container runtime interface.

func NewRuntime

func NewRuntime(
	shimmyPath string,
	runtimePath string,
	rootPath string,
) Runtime

type RuntimeSpec

type RuntimeSpec []byte

func NewSpec

func NewSpec(opts SpecOptions) (RuntimeSpec, error)

type SpecOptions

type SpecOptions struct {
	Command      string
	Args         []string
	RootPath     string
	RootReadonly bool
}

type StateResp

type StateResp struct {
	Id      string `json:"id"`
	Pid     int    `json:"pid"`
	Status  string `json:"status"`
	Created string `json:"created"`
}

Jump to

Keyboard shortcuts

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