contback

package
v3.14.0 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2026 License: Apache-2.0 Imports: 26 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrRuntimeUnavailable = errors.New("requested runtime unavailable")

Functions

func CleanupProject added in v3.7.2

func CleanupProject(ctx context.Context, projectName string, opts CleanupProjectOptions) error

func SkipIfUnavailable

func SkipIfUnavailable(mode string)

SkipIfUnavailable skips the current spec when the backend it needs is not available on this host, for specs that never touch the backend directly.

Types

type BaseContainerBackend

type BaseContainerBackend struct {
	CommonCliArgs []string
	Isolation     thirdparty.Isolation
}

type BuildahContainer added in v3.13.0

type BuildahContainer struct {
	ID      string
	ImageID string
	Names   []string
}

type BuildahInspect

type BuildahInspect struct {
	Docker struct {
		Author       string                 `json:"author"`
		Config       manifest.Schema2Config `json:"config"`
		Architecture string                 `json:"architecture"`
		Os           string                 `json:"os"`
		Variant      string                 `json:"variant"`
		History      interface{}            `json:"history"`
	} `json:"Docker"`
}

type BuildahStorageSnapshot added in v3.13.0

type BuildahStorageSnapshot struct {
	ProjectImageIDs []string
	Containers      []BuildahContainer
}

BuildahStorageSnapshot is what the Buildah storage werf builds into holds for a test project: the images labeled with the project and every container in the storage, whichever build created it.

func SnapshotBuildahStorage added in v3.13.0

func SnapshotBuildahStorage(ctx context.Context, projectName string) (BuildahStorageSnapshot, error)

SnapshotBuildahStorage reads the storage in-process, so it sees the containers werf created regardless of the buildah CLI version installed on the host.

type CleanupProjectOptions added in v3.7.2

type CleanupProjectOptions struct {
	Repositories []string
	BackendModes []string
}

type ContainerBackend

type ContainerBackend interface {
	Pull(ctx context.Context, image string)
	Exec(ctx context.Context, containerName string, cmds ...string)
	Rm(ctx context.Context, containerName string)

	RunSleepingContainer(ctx context.Context, containerName, image string)
	GetImageInspect(ctx context.Context, image string) DockerImageInspect
	ExpectCmdsToSucceed(ctx context.Context, image string, cmds ...string)
}

func NewContainerBackend

func NewContainerBackend(mode string) ContainerBackend

NewContainerBackend skips the current spec when the requested backend is not available on this host.

func NewDockerBackend

func NewDockerBackend() ContainerBackend

func NewNativeBuildahBackend

func NewNativeBuildahBackend(isolation thirdparty.Isolation, storageDriver buildah.StorageDriver) ContainerBackend

type DockerBackend

type DockerBackend struct {
	BaseContainerBackend
}

func (*DockerBackend) Exec

func (r *DockerBackend) Exec(ctx context.Context, containerName string, cmds ...string)

func (*DockerBackend) ExpectCmdsToSucceed

func (r *DockerBackend) ExpectCmdsToSucceed(ctx context.Context, image string, cmds ...string)

func (*DockerBackend) GetImageInspect

func (r *DockerBackend) GetImageInspect(ctx context.Context, image string) DockerImageInspect

func (*DockerBackend) Pull

func (r *DockerBackend) Pull(ctx context.Context, image string)

func (*DockerBackend) Rm

func (r *DockerBackend) Rm(ctx context.Context, containerName string)

func (*DockerBackend) RunSleepingContainer

func (r *DockerBackend) RunSleepingContainer(ctx context.Context, containerName, image string)

type DockerImageInspect

type DockerImageInspect struct {
	Author       string
	Config       manifest.Schema2Config
	Architecture string
	Os           string
	Variant      string
	History      interface{}
}

type DockerInspect

type DockerInspect []DockerImageInspect

type NativeBuildahBackend

type NativeBuildahBackend struct {
	BaseContainerBackend
}

func (*NativeBuildahBackend) Exec

func (r *NativeBuildahBackend) Exec(ctx context.Context, containerName string, cmds ...string)

func (*NativeBuildahBackend) ExpectCmdsToSucceed

func (r *NativeBuildahBackend) ExpectCmdsToSucceed(ctx context.Context, image string, cmds ...string)

func (*NativeBuildahBackend) GetImageInspect

func (r *NativeBuildahBackend) GetImageInspect(ctx context.Context, image string) DockerImageInspect

func (*NativeBuildahBackend) Pull

func (r *NativeBuildahBackend) Pull(ctx context.Context, image string)

func (*NativeBuildahBackend) Rm

func (r *NativeBuildahBackend) Rm(ctx context.Context, containerName string)

func (*NativeBuildahBackend) RmiByRepoRef

func (r *NativeBuildahBackend) RmiByRepoRef(ctx context.Context, repoRef string)

RmiByRepoRef removes every local image tagged under repoRef from the containers storage.

func (*NativeBuildahBackend) RunSleepingContainer

func (r *NativeBuildahBackend) RunSleepingContainer(ctx context.Context, containerName, image string)

Jump to

Keyboard shortcuts

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