registry

package
v0.0.0-...-7eed66f Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2017 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseTag

func ParseTag(name reference.Named) string

ParseTag returns the tag corresponding to the given image name

func WalkImages

func WalkImages(r dim.Repository) <-chan *dim.RegistryImage

WalkImages walks through all images of the repository and writes them in the given channel

func WalkRepositories

func WalkRepositories(c dim.RegistryClient) <-chan dim.Repository

WalkRepositories walks through all repositories and send them in the given channel

Types

type Client

type Client struct {
	client.Registry
	// contains filtered or unexported fields
}

Client implements RegistryClient interface

func New

func New(c *cli.Cli, registryAuth *types.AuthConfig, registryURL string) (*Client, error)

New creates a registry client. Handles getting right credentials from user

func SilentNew

func SilentNew(c *cli.Cli, registryAuth *types.AuthConfig, registryURL string) (*Client, error)

SilentNew creates a registry client but doesn't prompt credentials when required

func (*Client) DeleteImage

func (c *Client) DeleteImage(parsedName reference.Named) error

DeleteImage deletes the image on the remote registry

func (*Client) NewRepository

func (c *Client) NewRepository(parsedName reference.Named) (dim.Repository, error)

NewRepository creates a Repository object to query the registry about a specific repository

func (*Client) PrintImageInfo

func (c *Client) PrintImageInfo(w io.Writer, parsedName reference.Named, tpl *template.Template) error

PrintImageInfo prints the info about an image available on the remote registry

func (*Client) Search

func (c *Client) Search(query, advanced string, offset, maxResults int) (*dim.SearchResults, error)

Search runs a search against the registry, handling dim advanced querying option

func (*Client) ServerVersion

func (c *Client) ServerVersion() (*dim.Info, error)

ServerVersion read dim server version information

func (*Client) WalkRepositories

func (c *Client) WalkRepositories() <-chan dim.Repository

WalkRepositories walks through all repositories and send them in the given channel

type Repository

type Repository struct {
	distribution.Repository
	// contains filtered or unexported fields
}

Repository implements Repository interface

func (*Repository) AllTags

func (r *Repository) AllTags() ([]string, error)

AllTags returns all existing tag for this repository instance

func (*Repository) DeleteImage

func (r *Repository) DeleteImage(tag string) error

DeleteImage sends a delete request on tag

func (*Repository) Image

func (r *Repository) Image(tag string) (img *dim.RegistryImage, err error)

Image return image info for a given tag

func (*Repository) ImageFromManifest

func (r *Repository) ImageFromManifest(tagDigest digest.Digest, tag string) (image *dim.RegistryImage, err error)

ImageFromManifest returns image information from its manifest digest

func (*Repository) WalkImages

func (r *Repository) WalkImages() <-chan *dim.RegistryImage

WalkImages walks through all images of the repository and writes them in the given channel

Jump to

Keyboard shortcuts

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