Documentation
¶
Overview ¶
Package registry provides operations on image registries
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client interface {
// Digest returns the digest of the given image or an error if the image does not exist or the digest is unavailable.
Digest(image.Name) (image.Digest, error)
// Copy copies the given source image to the given target and returns the image's digest (which is preserved) and
// the size in bytes of the raw image manifest.
Copy(source image.Name, target image.Name) (image.Digest, int64, error)
// NewLayout creates a Layout for the Client and creates a corresponding directory containing a new OCI image layout at
// the given file system path.
NewLayout(path string) (Layout, error)
// ReadLayout creates a Layout for the Client from the given file system path of a directory containing an existing
// OCI image layout.
ReadLayout(path string) (Layout, error)
}
Client provides a way of interacting with image registries.
type Image ¶
type Image interface {
// Digest returns the repository digest of the image.
Digest() (image.Digest, error)
// Write writes the image to a given reference and returns the image's digest and size.
Write(target image.Name) (image.Digest, int64, error)
}
Image represents an abstract image which could be an image manifest or an image index (e.g. a multi-arch image).
type Layout ¶
type Layout interface {
// Add adds the image at the given image reference to the layout and returns the image's digest.
Add(n image.Name) (image.Digest, error)
// Push pushes the image with the given digest from the layout to the given image reference.
Push(digest image.Digest, name image.Name) error
// Find returns the digest of an image in the layout with the given image reference.
Find(n image.Name) (image.Digest, error)
}
A Layout abstracts an OCI image layout on disk.
Directories
¶
| Path | Synopsis |
|---|---|
|
path/pathfakes
Code generated by counterfeiter.
|
Code generated by counterfeiter. |
|
registryclientfakes
Code generated by counterfeiter.
|
Code generated by counterfeiter. |
|
Code generated by counterfeiter.
|
Code generated by counterfeiter. |
|
Code generated by counterfeiter.
|
Code generated by counterfeiter. |
Click to show internal directories.
Click to hide internal directories.