docker

package
v0.17.3 Latest Latest
Warning

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

Go to latest
Published: Jan 12, 2022 License: MIT Imports: 12 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 {
	Image    string
	Tag      string
	Token    string
	Username string
	Password string
}

Docker contains various information to interact with a docker registry

func (*Docker) Condition

func (d *Docker) Condition(source string) (bool, error)

Condition checks if a docker image with a specific tag is published We assume that if we can't retrieve the docker image digest, then it means it doesn't exist.

func (*Docker) ConditionFromSCM

func (d *Docker) ConditionFromSCM(source string, scm scm.ScmHandler) (bool, error)

ConditionFromSCM returns an error because it's not supported

func (*Docker) IsDockerRegistry

func (d *Docker) IsDockerRegistry() (bool, error)

IsDockerRegistry validates that we are on docker registry api https://docs.docker.com/registry/spec/api/#api-version-check

func (*Docker) Source

func (d *Docker) Source(workingDir string) (string, error)

Source retrieve docker image tag digest from a registry

func (*Docker) Validate

func (d *Docker) Validate() (errs []error)

Validate ensure parameters are set

type Registry

type Registry interface {
	Digest() (string, error)
}

Registry is an interface for every docker registry api

Directories

Path Synopsis
registry

Jump to

Keyboard shortcuts

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