Documentation
¶
Index ¶
- func Convert(ctx context.Context, client *containerd.Client, output io.Writer, ...) error
- func Crypt(ctx context.Context, encrypt bool, cli *client.Client, output io.Writer, ...) error
- func EnsureAllContent(ctx context.Context, client *containerd.Client, srcName string, ...) error
- func EnsureImage(ctx context.Context, client *containerd.Client, rawRef string, ...) (*imgutil.EnsuredImage, error)
- func Inspect(ctx context.Context, client *containerd.Client, identifiers []string, ...) error
- func List(ctx context.Context, client *containerd.Client, ...) ([]images.Image, error)
- func ListCommandHandler(ctx context.Context, client *containerd.Client, options *options.ImageList) error
- func Prune(ctx context.Context, client *containerd.Client, globalOptions *options.Global, ...) error
- func Pull(ctx context.Context, client *containerd.Client, rawRef string, ...) error
- func Push(ctx context.Context, client *containerd.Client, rawRef string, ...) error
- func Remove(ctx context.Context, client *containerd.Client, args []string, ...) error
- func Save(ctx context.Context, client *containerd.Client, images []string, ...) error
- func Tag(ctx context.Context, client *containerd.Client, options options.ImageTag) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EnsureAllContent ¶
func EnsureImage ¶
func EnsureImage(ctx context.Context, client *containerd.Client, rawRef string, options options.ImagePull) (*imgutil.EnsuredImage, error)
EnsureImage pulls an image from registry.
func Inspect ¶
func Inspect(ctx context.Context, client *containerd.Client, identifiers []string, options options.ImageInspect) error
Inspect prints detailed information of each image in `images`.
func List ¶
func List(ctx context.Context, client *containerd.Client, filters, nameAndRefFilter []string) ([]images.Image, error)
List queries containerd client to get image list and only returns those matching given filters.
Supported filters: - before=<image>[:<tag>]: Images created before given image (exclusive) - since=<image>[:<tag>]: Images created after given image (exclusive) - label=<key>[=<value>]: Matches images based on the presence of a label alone or a label and a value - dangling=true: Filter images by dangling - reference=<image>[:<tag>]: Filter images by reference (Matches both docker compatible wildcard pattern and regexp)
nameAndRefFilter has the format of `name==(<image>[:<tag>])|ID`, and they will be used when getting images from containerd, while the remaining filters are only applied after getting images from containerd, which means that having nameAndRefFilter may speed up the process if there are a lot of images in containerd.
func ListCommandHandler ¶
func ListCommandHandler(ctx context.Context, client *containerd.Client, options *options.ImageList) error
ListCommandHandler `List` and print images matching filters in `options`.
func Prune ¶
func Prune(ctx context.Context, client *containerd.Client, globalOptions *options.Global, opts options.ImagePrune) error
Prune will remove all dangling images. If all is specified, will also remove all images not referenced by any container.
func Pull ¶
func Pull(ctx context.Context, client *containerd.Client, rawRef string, options options.ImagePull) error
Pull pulls an image specified by `rawRef`.
func Push ¶
func Push(ctx context.Context, client *containerd.Client, rawRef string, options options.ImagePush) error
Push pushes an image specified by `rawRef`.
func Remove ¶
func Remove(ctx context.Context, client *containerd.Client, args []string, options options.ImageRemove) error
Remove removes a list of `images`.
Types ¶
This section is empty.