Documentation ¶
Index ¶
- Variables
- func IsBlobNotFound(err error) bool
- func IsImageNotFound(err error) bool
- func IsNotFound(err error) bool
- func IsRegistryNotFound(err error) bool
- func IsRepositoryNotFound(err error) bool
- func IsTagNotFound(err error) bool
- func NewImageNotFoundError(repository, image, tag string) error
- type Client
- type Connection
- type Descriptor
- type DockerFSLayer
- type DockerHistory
- type DockerImageManifest
- type Image
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ImageScheme = runtime.NewScheme()
)
Functions ¶
func IsBlobNotFound ¶
func IsImageNotFound ¶
func IsNotFound ¶
func IsRegistryNotFound ¶
func IsRepositoryNotFound ¶
func IsTagNotFound ¶
func NewImageNotFoundError ¶
Types ¶
type Client ¶
type Client interface { // Connect to a Docker registry by name. Pass "" for the Docker Hub Connect(registry string, allowInsecure bool) (Connection, error) }
Client includes methods for accessing a Docker registry by name.
type Connection ¶
type Connection interface { // ImageTags will return a map of the tags for the image by namespace and name. // If namespace is not specified, will default to "library" for Docker hub. ImageTags(namespace, name string) (map[string]string, error) // ImageByID will return the requested image by namespace, name, and ID. // If namespace is not specified, will default to "library" for Docker hub. ImageByID(namespace, name, id string) (*Image, error) // ImageByTag will return the requested image by namespace, name, and tag // (if not specified, "latest"). // If namespace is not specified, will default to "library" for Docker hub. ImageByTag(namespace, name, tag string) (*Image, error) // ImageManifest will return the raw image manifest and digest by namespace, // name, and tag. ImageManifest(namespace, name, tag string) (string, []byte, error) }
Connection allows you to retrieve data from a Docker V1/V2 registry.
type Descriptor ¶
type Descriptor struct { // MediaType describe the type of the content. All text based formats are // encoded as utf-8. MediaType string `json:"mediaType,omitempty"` // Size in bytes of content. Size int64 `json:"size,omitempty"` // Digest uniquely identifies the content. A byte stream can be verified // against against this digest. Digest string `json:"digest,omitempty"` }
Descriptor describes targeted content. Used in conjunction with a blob store, a descriptor can be used to fetch, store and target any kind of blob. The struct also describes the wire protocol format. Fields should only be added but never changed.
type DockerFSLayer ¶
type DockerFSLayer struct { // DockerBlobSum is the tarsum of the referenced filesystem image layer // TODO make this digest.Digest once docker/distribution is in Godeps DockerBlobSum string `json:"blobSum"` }
DockerFSLayer is a container struct for BlobSums defined in an image manifest
type DockerHistory ¶
type DockerHistory struct { // DockerV1Compatibility is the raw v1 compatibility information DockerV1Compatibility string `json:"v1Compatibility"` }
DockerHistory stores unstructured v1 compatibility information
type DockerImageManifest ¶
type DockerImageManifest struct { SchemaVersion int `json:"schemaVersion"` MediaType string `json:"mediaType,omitempty"` // schema1 Name string `json:"name"` Tag string `json:"tag"` Architecture string `json:"architecture"` FSLayers []DockerFSLayer `json:"fsLayers"` History []DockerHistory `json:"history"` // schema2 Layers []Descriptor `json:"layers"` Config Descriptor `json:"config"` }
DockerImageManifest represents the Docker v2 image format.
type Image ¶
type Image struct { Image godockerclient.Image // Does this registry support pull by ID PullByID bool }
Click to show internal directories.
Click to hide internal directories.