docker

package
v0.17.0 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2021 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Docker

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

Docker returns docker client

func New

func New() (Docker, error)

New is the factory method to return docker client

func (Docker) ReplicateImage

func (d Docker) ReplicateImage(ctx context.Context, imageRef, imagePath string, dest RegistryConfig) error

ReplicateImage tags the given imagePath and pushes it to the given dest registry.

type RegistryConfig

type RegistryConfig struct {
	URL      *url.URL
	Username string
	Password string
}

RegistryConfig holds the config for docker registry

func (RegistryConfig) GetAuthConfig

func (c RegistryConfig) GetAuthConfig() types.AuthConfig

GetAuthConfig returns the docker registry authConfig

func (RegistryConfig) GetRegistryAuth

func (c RegistryConfig) GetRegistryAuth() (string, error)

GetRegistryAuth returns the json encoded docker registry auth

Jump to

Keyboard shortcuts

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