docker

package
v0.0.0-...-c809886 Latest Latest
Warning

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

Go to latest
Published: May 29, 2023 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WalkDockerfiles

func WalkDockerfiles(root string, filter func(string) bool, walkFunc func(path string, parsed *parser.Result) error) error

Types

type Environment

type Environment struct {
	updateaction.Environment
	ShaPinning bool `env:"INPUT_SHA_PINNING" envDefault:"false"`
}

func (*Environment) NewUpdater

func (c *Environment) NewUpdater(root string) updater.Updater

type ImagePinner

type ImagePinner interface {
	// Pin normalizes Docker image name to sha256 pinned image.
	Pin(ctx context.Context, image string) (string, error)
	Unpin(ctx context.Context, image, hash string) (string, error)
}

type Interpolation

type Interpolation struct {
	Vars map[string]string
	// contains filtered or unexported fields
}

Interpolation attempts to interpolate a variable Dockerfile string Easily fooled by duplicate ARGs

func NewInterpolation

func NewInterpolation(parsed *parser.Result) *Interpolation

func (*Interpolation) Interpolate

func (i *Interpolation) Interpolate(s string) string

type RemoteRegistries

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

func NewRemoteRegistries

func NewRemoteRegistries() *RemoteRegistries

func (*RemoteRegistries) Pin

func (r *RemoteRegistries) Pin(ctx context.Context, image string) (string, error)

func (*RemoteRegistries) Tags

func (r *RemoteRegistries) Tags(ctx context.Context, image string) ([]string, error)

func (*RemoteRegistries) Unpin

func (r *RemoteRegistries) Unpin(ctx context.Context, image, hash string) (string, error)

type TagLister

type TagLister interface {
	// Tags returns potential version tags given a updater.Dependency path
	Tags(ctx context.Context, path string) ([]string, error)
}

type Updater

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

func NewUpdater

func NewUpdater(root string, opts ...UpdaterOpt) *Updater

func (*Updater) ApplyUpdate

func (u *Updater) ApplyUpdate(ctx context.Context, update updater.Update) error

func (*Updater) Check

func (u *Updater) Check(ctx context.Context, dependency updater.Dependency, filter func(string) bool) (*updater.Update, error)

func (*Updater) Dependencies

func (u *Updater) Dependencies(_ context.Context) ([]updater.Dependency, error)

func (*Updater) Name

func (u *Updater) Name() string

type UpdaterOpt

type UpdaterOpt func(*Updater)

func WithImagePinner

func WithImagePinner(pinner ImagePinner) UpdaterOpt

func WithShaPinning

func WithShaPinning(shaPinning bool) UpdaterOpt

func WithTagsLister

func WithTagsLister(tags TagLister) UpdaterOpt

Jump to

Keyboard shortcuts

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