containerd

package
v0.0.0-...-7d2ea42 Latest Latest
Warning

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

Go to latest
Published: Jun 9, 2024 License: Apache-2.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Checkpoint

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

Checkpoint 建立 Pod 检查点

func (*Checkpoint) Do

func (c *Checkpoint) Do(ctx context.Context) error

Do 执行建立 Pod 检查点操作

type Manager

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

Manager 基于 containerd 的 common.PodCRManager 的实现

func New

func New(endpoint, tmpdir string, retainCheckpointImages bool) (*Manager, error)

New 创建一个 *Manager

func (*Manager) Checkpoint

func (h *Manager) Checkpoint(ctx context.Context, checkpointID, namespace, name string, tw *tar.Writer) error

Checkpoint 建立 Pod 检查点,并导出到 tw

func (*Manager) Restore

func (h *Manager) Restore(ctx context.Context, tr *tar.Reader, opts common.RestoreOptions) error

Restore 从 tr 读取 Pod 检查点并还原 Pod

type Restore

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

Restore 从 Pod 检查点还原

func (*Restore) Do

func (r *Restore) Do(ctx context.Context) error

Do 执行从 Pod 检查点还原操作

type SandboxInfo

type SandboxInfo struct {
	// 沙盒 ID
	ID string `json:"id"`

	// 沙盒容器 1 号进程在宿主机上的 Pid
	Pid int `json:"pid"`
	// 沙盒配置
	Config *runtimev1.PodSandboxConfig `json:"config,omitempty"`
	// 沙盒运行时配置
	RuntimeSpec *ociruntime.Spec `json:"runtimeSpec,omitempty"`
}

SandboxInfo 沙盒信息

Jump to

Keyboard shortcuts

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