image

package
v1.2.20 Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BuildConfig

type BuildConfig = types.ImageBuildOptions

BuildConfig is the configuration for building a image

type Image

type Image interface {
	List(ctx context.Context, opts ...func(cfg *ListConfig)) (images []entity.Image, err error)
	Inspect(ctx context.Context, id string, opts ...func(cfg *InspectConfig)) (*types.ImageInspect, error)
	Remove(ctx context.Context, id string, opts ...func(cfg *RemoveConfig)) ([]ti.DeleteResponse, error)
	//
	History(ctx context.Context, id string) ([]entity.ImageHistory, error)
	//
	Build(ctx context.Context, src string, opts ...func(cfg *BuildConfig)) error
	//
	Pull(ctx context.Context, name string, opts ...func(cfg *PullConfig)) error
	Push(ctx context.Context, name string, opts ...func(cfg *PushConfig)) error
	//
	Tag(ctx context.Context, source, target string) error
	//
	Prune(ctx context.Context, opts ...func(cfg *PruneConfig)) (types.ImagesPruneReport, error)
}

Image is the docker image client interface

func New

func New(client *client.Client) Image

New creates a docker image client

type InspectConfig added in v1.2.10

type InspectConfig struct {
}

type ListConfig added in v1.2.10

type ListConfig struct {
	// All controls whether all images in the graph are filtered, or just
	// the heads.
	All bool

	// Filters is a JSON-encoded set of filter arguments.
	Filters filters.Args

	// SharedSize indicates whether the shared size of images should be computed.
	SharedSize bool

	// ContainerCount indicates whether container count should be computed.
	ContainerCount bool
}

type PruneConfig added in v1.2.10

type PruneConfig = filters.Args

type PullConfig

type PullConfig struct {
	Auth struct {
		Username string
		Password string
	}
	Platform string
	//
	Stdout io.Writer
}

PullConfig is the options for pulling an image

type PushConfig

type PushConfig struct {
	Auth struct {
		Username string
		Password string
		Server   string
	}

	Stdout io.Writer
}

PushConfig is the configuration for pushing an image

type RemoveConfig added in v1.2.10

type RemoveConfig struct {
	Force         bool
	PruneChildren bool
}

Jump to

Keyboard shortcuts

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