Documentation ¶
Index ¶
- Constants
- func BuildahWithFuseDockerArgs(storageContainerName, dockerConfigDir string) []string
- func GetBasicBuildahCliArgs(driver StorageDriver) ([]string, error)
- func GetDefaultIsolation() (thirdparty.Isolation, error)
- func GetFuseOverlayfsOptions() ([]string, error)
- func NativeProcessStartupHook() bool
- func NewNativeStoreOptions(rootlessUID int, driver StorageDriver) (*thirdparty.StoreOptions, error)
- func ProcessStartupHook(mode Mode) (bool, error)
- type BaseBuildah
- type BaseBuildahOpts
- type BuildFromDockerfileOpts
- type Buildah
- type BuildahOpts
- type CommitOpts
- type CommonBuildahOpts
- type CommonOpts
- type ConfigOpts
- type DockerWithFuseBuildah
- func (b *DockerWithFuseBuildah) BuildFromDockerfile(ctx context.Context, dockerfile []byte, opts BuildFromDockerfileOpts) (string, error)
- func (b *DockerWithFuseBuildah) Commit(ctx context.Context, container string, opts CommitOpts) (string, error)
- func (b *DockerWithFuseBuildah) Config(ctx context.Context, container string, opts ConfigOpts) error
- func (b *DockerWithFuseBuildah) FromCommand(ctx context.Context, container, image string, opts FromCommandOpts) (string, error)
- func (b *DockerWithFuseBuildah) Inspect(ctx context.Context, ref string) (*thirdparty.BuilderInfo, error)
- func (b *DockerWithFuseBuildah) Mount(ctx context.Context, container string, opts MountOpts) (string, error)
- func (b *DockerWithFuseBuildah) Pull(ctx context.Context, ref string, opts PullOpts) error
- func (b *DockerWithFuseBuildah) Push(ctx context.Context, ref string, opts PushOpts) error
- func (b *DockerWithFuseBuildah) Rm(ctx context.Context, ref string, opts RmOpts) error
- func (b *DockerWithFuseBuildah) Rmi(ctx context.Context, ref string, opts RmiOpts) error
- func (b *DockerWithFuseBuildah) RunCommand(ctx context.Context, container string, command []string, opts RunCommandOpts) error
- func (b *DockerWithFuseBuildah) Tag(ctx context.Context, ref, newRef string, opts TagOpts) error
- func (b *DockerWithFuseBuildah) Umount(ctx context.Context, container string, opts UmountOpts) error
- type DockerWithFuseModeOpts
- type FromCommandOpts
- type Mode
- type MountOpts
- type NativeBuildah
- func (b *NativeBuildah) BuildFromDockerfile(ctx context.Context, dockerfile []byte, opts BuildFromDockerfileOpts) (string, error)
- func (b *NativeBuildah) Commit(ctx context.Context, container string, opts CommitOpts) (string, error)
- func (b *NativeBuildah) Config(ctx context.Context, container string, opts ConfigOpts) error
- func (b *NativeBuildah) FromCommand(ctx context.Context, container, image string, opts FromCommandOpts) (string, error)
- func (b *NativeBuildah) Inspect(ctx context.Context, ref string) (*thirdparty.BuilderInfo, error)
- func (b *NativeBuildah) Mount(ctx context.Context, container string, opts MountOpts) (string, error)
- func (b *NativeBuildah) Pull(ctx context.Context, ref string, opts PullOpts) error
- func (b *NativeBuildah) Push(ctx context.Context, ref string, opts PushOpts) error
- func (b *NativeBuildah) Rm(ctx context.Context, ref string, opts RmOpts) error
- func (b *NativeBuildah) Rmi(ctx context.Context, ref string, opts RmiOpts) error
- func (b *NativeBuildah) RunCommand(ctx context.Context, container string, command []string, opts RunCommandOpts) error
- func (b *NativeBuildah) Tag(_ context.Context, ref, newRef string, opts TagOpts) error
- func (b *NativeBuildah) Umount(ctx context.Context, container string, opts UmountOpts) error
- type NativeModeOpts
- type PullOpts
- type PushOpts
- type RmOpts
- type RmiOpts
- type RunCommandOpts
- type RunMount
- type StorageDriver
- type StoreOptions
- type TagOpts
- type UmountOpts
Constants ¶
View Source
const ( DefaultShmSize = "65536k" DefaultSignaturePolicy = `` /* 126-byte string literal not displayed */ DefaultRegistriesConfig = `unqualified-search-registries = ["docker.io"]` BuildahImage = "registry.werf.io/werf/buildah:v1.22.3-1" BuildahStorageContainerName = "werf-buildah-storage" DefaultStorageDriver StorageDriver = StorageDriverOverlay )
View Source
const ( MaxPullPushRetries = 3 PullPushRetryDelay = 2 * time.Second )
Variables ¶
This section is empty.
Functions ¶
func BuildahWithFuseDockerArgs ¶ added in v1.2.35
func GetBasicBuildahCliArgs ¶ added in v1.2.50
func GetBasicBuildahCliArgs(driver StorageDriver) ([]string, error)
func GetDefaultIsolation ¶ added in v1.2.48
func GetDefaultIsolation() (thirdparty.Isolation, error)
func GetFuseOverlayfsOptions ¶ added in v1.2.50
func NativeProcessStartupHook ¶ added in v1.2.48
func NativeProcessStartupHook() bool
func NewNativeStoreOptions ¶ added in v1.2.48
func NewNativeStoreOptions(rootlessUID int, driver StorageDriver) (*thirdparty.StoreOptions, error)
func ProcessStartupHook ¶
Types ¶
type BaseBuildah ¶
type BaseBuildah struct { Isolation thirdparty.Isolation TmpDir string InstanceTmpDir string ConfigTmpDir string SignaturePolicyPath string RegistriesConfigPath string RegistriesConfigDirPath string Insecure bool }
func NewBaseBuildah ¶
func NewBaseBuildah(tmpDir string, opts BaseBuildahOpts) (*BaseBuildah, error)
func (*BaseBuildah) NewSessionTmpDir ¶
func (b *BaseBuildah) NewSessionTmpDir() (string, error)
type BaseBuildahOpts ¶ added in v1.2.35
type BaseBuildahOpts struct { Isolation thirdparty.Isolation Insecure bool }
type BuildFromDockerfileOpts ¶
type Buildah ¶
type Buildah interface { Tag(ctx context.Context, ref, newRef string, opts TagOpts) error Push(ctx context.Context, ref string, opts PushOpts) error BuildFromDockerfile(ctx context.Context, dockerfile []byte, opts BuildFromDockerfileOpts) (string, error) RunCommand(ctx context.Context, container string, command []string, opts RunCommandOpts) error FromCommand(ctx context.Context, container, image string, opts FromCommandOpts) (string, error) Pull(ctx context.Context, ref string, opts PullOpts) error Inspect(ctx context.Context, ref string) (*thirdparty.BuilderInfo, error) Rm(ctx context.Context, ref string, opts RmOpts) error Rmi(ctx context.Context, ref string, opts RmiOpts) error Mount(ctx context.Context, container string, opts MountOpts) (string, error) Umount(ctx context.Context, container string, opts UmountOpts) error Commit(ctx context.Context, container string, opts CommitOpts) (string, error) Config(ctx context.Context, container string, opts ConfigOpts) error }
func NewBuildah ¶
func NewBuildah(mode Mode, opts BuildahOpts) (b Buildah, err error)
type BuildahOpts ¶
type BuildahOpts struct { CommonBuildahOpts DockerWithFuseModeOpts NativeModeOpts }
type CommitOpts ¶ added in v1.2.81
type CommitOpts struct { CommonOpts Image string }
type CommonBuildahOpts ¶
type CommonBuildahOpts struct { Isolation *thirdparty.Isolation StorageDriver *StorageDriver TmpDir string Insecure bool }
type CommonOpts ¶
type ConfigOpts ¶ added in v1.2.81
type DockerWithFuseBuildah ¶
type DockerWithFuseBuildah struct { BaseBuildah // contains filtered or unexported fields }
func NewDockerWithFuseBuildah ¶
func NewDockerWithFuseBuildah(commonOpts CommonBuildahOpts, opts DockerWithFuseModeOpts) (*DockerWithFuseBuildah, error)
func (*DockerWithFuseBuildah) BuildFromDockerfile ¶
func (b *DockerWithFuseBuildah) BuildFromDockerfile(ctx context.Context, dockerfile []byte, opts BuildFromDockerfileOpts) (string, error)
func (*DockerWithFuseBuildah) Commit ¶ added in v1.2.81
func (b *DockerWithFuseBuildah) Commit(ctx context.Context, container string, opts CommitOpts) (string, error)
func (*DockerWithFuseBuildah) Config ¶ added in v1.2.81
func (b *DockerWithFuseBuildah) Config(ctx context.Context, container string, opts ConfigOpts) error
func (*DockerWithFuseBuildah) FromCommand ¶
func (b *DockerWithFuseBuildah) FromCommand(ctx context.Context, container, image string, opts FromCommandOpts) (string, error)
func (*DockerWithFuseBuildah) Inspect ¶
func (b *DockerWithFuseBuildah) Inspect(ctx context.Context, ref string) (*thirdparty.BuilderInfo, error)
TODO: make it more generic to handle not only images
func (*DockerWithFuseBuildah) RunCommand ¶
func (b *DockerWithFuseBuildah) RunCommand(ctx context.Context, container string, command []string, opts RunCommandOpts) error
func (*DockerWithFuseBuildah) Umount ¶ added in v1.2.46
func (b *DockerWithFuseBuildah) Umount(ctx context.Context, container string, opts UmountOpts) error
type DockerWithFuseModeOpts ¶
type DockerWithFuseModeOpts struct{}
type FromCommandOpts ¶
type FromCommandOpts CommonOpts
type MountOpts ¶ added in v1.2.46
type MountOpts CommonOpts
type NativeBuildah ¶ added in v1.2.48
type NativeBuildah struct { BaseBuildah Store storage.Store Runtime libimage.Runtime DefaultSystemContext imgtypes.SystemContext DefaultCommonBuildOptions define.CommonBuildOptions // contains filtered or unexported fields }
func NewNativeBuildah ¶ added in v1.2.48
func NewNativeBuildah(commonOpts CommonBuildahOpts, opts NativeModeOpts) (*NativeBuildah, error)
func (*NativeBuildah) BuildFromDockerfile ¶ added in v1.2.48
func (b *NativeBuildah) BuildFromDockerfile(ctx context.Context, dockerfile []byte, opts BuildFromDockerfileOpts) (string, error)
func (*NativeBuildah) Commit ¶ added in v1.2.81
func (b *NativeBuildah) Commit(ctx context.Context, container string, opts CommitOpts) (string, error)
func (*NativeBuildah) Config ¶ added in v1.2.81
func (b *NativeBuildah) Config(ctx context.Context, container string, opts ConfigOpts) error
func (*NativeBuildah) FromCommand ¶ added in v1.2.48
func (b *NativeBuildah) FromCommand(ctx context.Context, container, image string, opts FromCommandOpts) (string, error)
func (*NativeBuildah) Inspect ¶ added in v1.2.48
func (b *NativeBuildah) Inspect(ctx context.Context, ref string) (*thirdparty.BuilderInfo, error)
Inspect returns nil, nil if image not found.
func (*NativeBuildah) RunCommand ¶ added in v1.2.48
func (b *NativeBuildah) RunCommand(ctx context.Context, container string, command []string, opts RunCommandOpts) error
func (*NativeBuildah) Umount ¶ added in v1.2.48
func (b *NativeBuildah) Umount(ctx context.Context, container string, opts UmountOpts) error
type NativeModeOpts ¶ added in v1.2.48
type NativeModeOpts struct {
Platform string
}
type PullOpts ¶
type PullOpts CommonOpts
type PushOpts ¶
type PushOpts CommonOpts
type RmOpts ¶ added in v1.2.81
type RmOpts CommonOpts
type RmiOpts ¶
type RmiOpts struct { CommonOpts Force bool }
type RunCommandOpts ¶
type RunCommandOpts struct { CommonOpts WorkingDir string User string Args []string Mounts []specs.Mount }
type StorageDriver ¶ added in v1.2.48
type StorageDriver string
const ( StorageDriverOverlay StorageDriver = "overlay" StorageDriverVFS StorageDriver = "vfs" )
type StoreOptions ¶ added in v1.2.48
type TagOpts ¶
type TagOpts CommonOpts
type UmountOpts ¶ added in v1.2.46
type UmountOpts CommonOpts
Click to show internal directories.
Click to hide internal directories.