dockerregistry

package
v0.22.3 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DockerGenericRegistry

type DockerGenericRegistry struct {
	Auth      RegistryAuth
	WebClient httpclient.HTTPClient
}

DockerGenericRegistry is the main implementation of the Registry interface. It supports any v2 Registry API such as DockerHub, GHCR, etc.

func (DockerGenericRegistry) Digest

func (dgr DockerGenericRegistry) Digest(image dockerimage.Image) (string, error)

Digest retrieves the digest of the provided docker image from the registry

type Registry

type Registry interface {
	Digest(image dockerimage.Image) (string, error)
}

Registry is an interface to any Registry-specific metadata retriever (e.g. to retrieve Docker images metadatas)

func New

func New(hostname, username, password string) Registry

New returns a newly initialized Registry object.

type RegistryAuth

type RegistryAuth struct {
	Username string
	Password string
	Token    string
}

RegistryAuth holds the authentication element of a given registry

type RegistryEndpoints

type RegistryEndpoints struct {
	ApiService    string
	TokenService  string
	ScopedService string
}

RegistryEndpoints holds the URL endpoints for a given registry

Jump to

Keyboard shortcuts

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