docker

package
v0.0.0-...-306b231 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateAuthConfig

func CreateAuthConfig(username, password string) (string, error)

func GetDockerfileImages

func GetDockerfileImages(loc string) ([]string, error)

func IsBase64

func IsBase64(s string) bool

Types

type Client

type Client interface {
	Build(options types.ImageBuildOptions) error
	Pull(refStr string, options types.ImagePullOptions) error
	Push(image string, options types.ImagePushOptions) error
	Tag(source string, target string) error
	Login(auth registry.AuthConfig) error
}

type ClientImpl

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

func NewClient

func NewClient(opts ...client.Opt) *ClientImpl

func (*ClientImpl) Build

func (c *ClientImpl) Build(options types.ImageBuildOptions) error

func (*ClientImpl) Login

func (c *ClientImpl) Login(auth registry.AuthConfig) error

func (*ClientImpl) Pull

func (c *ClientImpl) Pull(refStr string, options types.ImagePullOptions) error

func (*ClientImpl) Push

func (c *ClientImpl) Push(image string, options types.ImagePushOptions) error

func (*ClientImpl) Tag

func (c *ClientImpl) Tag(source string, target string) error

type Service

type Service interface {
	Pull(imageRefURL, registryAuth string) error
	Push(imageRefURL, registryAuth string) error
	Build(dockerfile string, tags ...string) error
	Tag(src, dest string) error
	Login(auth string) error
}

type ServiceImpl

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

func NewService

func NewService(client Client) *ServiceImpl

func (*ServiceImpl) Build

func (s *ServiceImpl) Build(dockerfile string, tags ...string) error

func (*ServiceImpl) Login

func (s *ServiceImpl) Login(auth string) error

func (*ServiceImpl) Pull

func (s *ServiceImpl) Pull(imageRefURL, registryAuth string) error

Pull requests the docker host to pull an image from a remote repository. The full remote image path is required as well as authentication for the registry.

func (*ServiceImpl) Push

func (s *ServiceImpl) Push(imageRefURL, registryAuth string) error

Push requests the docker host to push an image to a remote repository. The full remote image path is required as well as authentication for the registry.

func (*ServiceImpl) Tag

func (s *ServiceImpl) Tag(src, dest string) error

Directories

Path Synopsis
Package mock_docker is a generated GoMock package.
Package mock_docker is a generated GoMock package.

Jump to

Keyboard shortcuts

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