buildah

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2023 License: Apache-2.0 Imports: 55 Imported by: 0

Documentation

Index

Constants

View Source
const (
	OCIManifestDir  = "oci-dir"
	OCIArchive      = "oci-archive"
	V2s2ManifestDir = "docker-dir"
	V2s2Archive     = "docker-archive"
)

TODO find a package to place these flags

Variables

View Source
var LoadError = errors.Errorf("failed to load new image")

Functions

func DiscoverKubefile

func DiscoverKubefile(path string) (foundFile string, err error)

DiscoverKubefile tries to find a Kubefile within the provided `path`.

func OpenBuilder added in v0.9.2

func OpenBuilder(ctx context.Context, store storage.Store, name string) (builder *buildah.Builder, err error)

func TruncateID added in v0.9.2

func TruncateID(id string, truncate bool) string

Types

type Engine

type Engine struct {
	*cobra.Command
	// contains filtered or unexported fields
}

func NewBuildahImageEngine

func NewBuildahImageEngine(configurations options.EngineGlobalConfigurations) (*Engine, error)

func (*Engine) AddToManifest

func (engine *Engine) AddToManifest(manifestName string, imageNameOrIDList []string, opts *options.ManifestAddOpts) error

AddToManifest : for `manifestName`: if it is not exist,will create a new one. if not, it must be an existed manifest name. for `imageNameOrIDList`: if element is a single image just add it, if element is a manifest will add it’s s all instance no matter what platform it is.

func (*Engine) Build

func (engine *Engine) Build(opts *options.BuildOptions) (string, error)

func (*Engine) Commit

func (engine *Engine) Commit(opts *options.CommitOptions) (string, error)

func (*Engine) Config added in v0.9.1

func (engine *Engine) Config(opts *options.ConfigOptions) error

func (*Engine) Copy

func (engine *Engine) Copy(opts *options.CopyOptions) error

Copy will copy files in the host to the container. this is a basic ability, but not used in sealer now.

func (*Engine) CreateContainer

func (engine *Engine) CreateContainer(opts *options.FromOptions) (string, error)

func (*Engine) CreateManifest

func (engine *Engine) CreateManifest(name string, opts *options.ManifestCreateOpts) (string, error)

func (*Engine) CreateWorkingContainer

func (engine *Engine) CreateWorkingContainer(opts *options.BuildRootfsOptions) (containerID string, err error)

CreateWorkingContainer will make a workingContainer with rootfs under /var/lib/containers/storage And then link rootfs to the DestDir And remember to call RemoveContainer to remove the link and remove the container(umount rootfs) manually.

func (*Engine) DeleteManifests

func (engine *Engine) DeleteManifests(names []string, opts *options.ManifestDeleteOpts) error

func (*Engine) ImageRuntime

func (engine *Engine) ImageRuntime() *libimage.Runtime

func (*Engine) ImageStore

func (engine *Engine) ImageStore() storage.Store

func (*Engine) Images

func (engine *Engine) Images(opts *options.ImagesOptions) error

func (*Engine) Inspect

func (engine *Engine) Inspect(opts *options.InspectOptions) (*imagev1.ImageSpec, error)

func (*Engine) InspectManifest

func (engine *Engine) InspectManifest(name string, opts *options.ManifestInspectOpts) (*libimage.ManifestListData, error)

func (*Engine) Load

func (engine *Engine) Load(opts *options.LoadOptions) error

func (*Engine) Login

func (engine *Engine) Login(opts *options.LoginOptions) error

func (*Engine) Logout

func (engine *Engine) Logout(opts *options.LogoutOptions) error

func (*Engine) LookupManifest

func (engine *Engine) LookupManifest(name string) (*libimage.ManifestList, error)

func (*Engine) Mount

func (engine *Engine) Mount(opts *options.MountOptions) ([]options.JSONMount, error)

func (*Engine) Pull

func (engine *Engine) Pull(opts *options.PullOptions) (string, error)

func (*Engine) Push

func (engine *Engine) Push(opts *options.PushOptions) error

func (*Engine) PushManifest

func (engine *Engine) PushManifest(name, destSpec string, opts *options.PushOptions) error

func (*Engine) RemoveContainer

func (engine *Engine) RemoveContainer(opts *options.RemoveContainerOptions) error

func (*Engine) RemoveFromManifest

func (engine *Engine) RemoveFromManifest(name string, instanceDigest digest.Digest, opts *options.ManifestRemoveOpts) error

func (*Engine) RemoveImage

func (engine *Engine) RemoveImage(opts *options.RemoveImageOptions) error

func (*Engine) Save

func (engine *Engine) Save(opts *options.SaveOptions) error

Save image as tar file, if image is multi-arch image, will save all its instances and manifest name as tar file.

func (*Engine) SystemContext

func (engine *Engine) SystemContext() *types.SystemContext

func (*Engine) Tag

func (engine *Engine) Tag(opts *options.TagOptions) error

Jump to

Keyboard shortcuts

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