registry

package
v0.0.0-...-b25b198 Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2023 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Package registry provides the Registry interface and implementation.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(c client.Client, config Config) *impl

New returns a new Registry instance.

Types

type Config

type Config struct {
	TKRNamespace       string
	VerifyRegistryCert bool
}

Config contains the controller manager context.

type Registry

type Registry interface {
	// ListImageTags lists all tags of the given image.
	ListImageTags(imageName string) ([]string, error)
	// GetFile gets the file content bundled in the given image:tag.
	// If filename is empty, it will get the first file.
	GetFile(imageWithTag string, filename string) ([]byte, error)
	// GetFiles get all the files content bundled in the given image:tag.
	GetFiles(imageWithTag string) (map[string][]byte, error)
	// DownloadBundle downloads OCI bundle similar to `imgpkg pull -b` command
	// It is recommended to use this function when downloading imgpkg bundle
	DownloadBundle(imageName, outputDir string) error
}

Registry defines the registry interface

Directories

Path Synopsis
internal
registry
Package registry defines a Registry interface and client for working for imkpkg images.
Package registry defines a Registry interface and client for working for imkpkg images.

Jump to

Keyboard shortcuts

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