container

package
v0.10.0 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2024 License: Apache-2.0 Imports: 28 Imported by: 0

Documentation

Overview

Package container comprises functions and structures related to container APIs

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterHandlers

func RegisterHandlers(r types.VersionedRouter, service Service, conf *config.Config, logger flog.Logger)

RegisterHandlers register all the supported endpoints related to the container APIs.

Types

type Service

type Service interface {
	GetPathToFilesInContainer(ctx context.Context, cid string, path string) (string, func(), error)
	Remove(ctx context.Context, cid string, force, removeVolumes bool) error
	Wait(ctx context.Context, cid string, condition string) (code int64, err error)
	Start(ctx context.Context, cid string) error
	Stop(ctx context.Context, cid string, timeout *time.Duration) error
	Restart(ctx context.Context, cid string, timeout time.Duration) error
	Create(ctx context.Context, image string, cmd []string, createOpt ncTypes.ContainerCreateOptions, netOpt ncTypes.NetworkOptions) (string, error)
	Inspect(ctx context.Context, cid string) (*types.Container, error)
	WriteFilesAsTarArchive(filePath string, writer io.Writer, slashDot bool) error
	Attach(ctx context.Context, cid string, opts *types.AttachOptions) error
	List(ctx context.Context, listOpts ncTypes.ContainerListOptions) ([]types.ContainerListItem, error)
	Rename(ctx context.Context, cid string, newName string, opts ncTypes.ContainerRenameOptions) error
	Logs(ctx context.Context, cid string, opts *types.LogsOptions) error
	ExtractArchiveInContainer(ctx context.Context, putArchiveOpt *types.PutArchiveOptions, body io.ReadCloser) error
	Stats(ctx context.Context, cid string) (<-chan *types.StatsJSON, error)
	ExecCreate(ctx context.Context, cid string, config types.ExecConfig) (string, error)
}

Jump to

Keyboard shortcuts

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