registry

package
v0.1.5 Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2023 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ContainsTag

func ContainsTag(tags []string, tag string) bool

ContainsTag determines whether a tag is found in a provided list of tags.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client works with OCI-compliant registries.

func NewClient

func NewClient(options ...ClientOption) (*Client, error)

NewClient returns a new registry client with config.

func (*Client) Login

func (c *Client) Login(ctx context.Context, host string, options ...LoginOption) error

Login logs into a registry.

func (*Client) Logout

func (c *Client) Logout(ctx context.Context, host string, opts ...LogoutOption) error

Logout logs out of a registry.

func (*Client) Pull

func (c *Client) Pull(
	ctx context.Context,
	ref string,
) (r *tar.Reader, closeFunc func() error, err error)

Pull downloads a chart from a registry.

type ClientOption

type ClientOption func(*Client)

ClientOption allows specifying various settings configurable by the user for overriding the defaults used when creating a new default client.

func ClientOptCredentialsFile

func ClientOptCredentialsFile(credentialsFile string) ClientOption

ClientOptCredentialsFile returns a function that sets the credentialsFile setting on a client options set.

func ClientOptDebug

func ClientOptDebug(debug bool) ClientOption

ClientOptDebug returns a function that sets the debug setting on client options set.

func ClientOptEnableCache

func ClientOptEnableCache(enableCache bool) ClientOption

ClientOptEnableCache returns a function that sets the enableCache setting on a client options set.

func ClientOptResolver

func ClientOptResolver(resolver remotes.Resolver) ClientOption

ClientOptEnableCache returns a function that sets the enableCache setting on a client options set.

func ClientOptWriter

func ClientOptWriter(out io.Writer) ClientOption

ClientOptWriter returns a function that sets the writer setting on client options set.

type LoginOption

type LoginOption func(*loginOperation)

LoginOption allows specifying various settings on login.

func LoginOptBasicAuth

func LoginOptBasicAuth(username, password string) LoginOption

LoginOptBasicAuth returns a function that sets the username/password settings on login.

func LoginOptInsecure

func LoginOptInsecure(insecure bool) LoginOption

LoginOptInsecure returns a function that sets the insecure setting on login.

type LogoutOption

type LogoutOption func(*logoutOperation)

LogoutOption allows specifying various settings on logout.

Jump to

Keyboard shortcuts

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