package v2

import "github.com/containerd/containerd/runtime/v2"

Index

Types

type Bundle

type Bundle struct {
	// ID of the bundle
	ID string
	// Path to the bundle
	Path string
	// Namespace of the bundle
	Namespace string
}

Bundle represents an OCI bundle

func LoadBundle

func LoadBundle(ctx context.Context, root, id string) (*Bundle, error)

LoadBundle loads an existing bundle from disk

func NewBundle

func NewBundle(ctx context.Context, root, state, id string, spec []byte) (b *Bundle, err error)

NewBundle returns a new bundle on disk

func (*Bundle) Delete

func (b *Bundle) Delete() error

Delete a bundle atomically

type Config

type Config struct {
	// Supported platforms
	Platforms []string `toml:"platforms"`
}

Config for the v2 runtime

type TaskManager

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

TaskManager manages v2 shim's and their tasks

func New

func New(ctx context.Context, root, state, containerdAddress, containerdTTRPCAddress string, events *exchange.Exchange, cs containers.Store) (*TaskManager, error)

New task manager for v2 shims

func (*TaskManager) Add

func (m *TaskManager) Add(ctx context.Context, task runtime.Task) error

Add a runtime task

func (*TaskManager) Create

func (m *TaskManager) Create(ctx context.Context, id string, opts runtime.CreateOpts) (_ runtime.Task, err error)

Create a new task

func (*TaskManager) Delete

func (m *TaskManager) Delete(ctx context.Context, id string)

Delete a runtime task

func (*TaskManager) Get

func (m *TaskManager) Get(ctx context.Context, id string) (runtime.Task, error)

Get a specific task

func (*TaskManager) ID

func (m *TaskManager) ID() string

ID of the task manager

func (*TaskManager) Tasks

func (m *TaskManager) Tasks(ctx context.Context, all bool) ([]runtime.Task, error)

Tasks lists all tasks

Source Files

binary.go bundle.go manager.go manager_windows.go process.go shim.go shim_windows.go

Directories

PathSynopsis
runtime/v2/runc
runtime/v2/runc/options
runtime/v2/shim
runtime/v2/task
Version
v1.4.4
Published
Mar 5, 2021
Platform
windows/amd64
Imports
34 packages
Last checked
24 seconds ago

Tools for package owners.