2021-10-18 13:51:51 +08:00
|
|
|
package internal
|
|
|
|
|
2022-05-10 18:11:37 +08:00
|
|
|
const (
|
2024-07-31 03:42:50 +08:00
|
|
|
// BuildahExternalArtifactsDir is the pattern passed to os.MkdirTemp()
|
|
|
|
// to generate a temporary directory which will be used to hold
|
|
|
|
// external items which are downloaded for a build, typically a tarball
|
|
|
|
// being used as an additional build context.
|
2022-05-10 18:11:37 +08:00
|
|
|
BuildahExternalArtifactsDir = "buildah-external-artifacts"
|
2025-04-30 05:04:20 +08:00
|
|
|
// SourceDateEpochName is both the name of the SOURCE_DATE_EPOCH
|
|
|
|
// environment variable and the built-in ARG that carries its value,
|
|
|
|
// whether it's read from the environment by our main(), or passed in
|
|
|
|
// via CLI or API flags.
|
2025-04-30 04:37:27 +08:00
|
|
|
SourceDateEpochName = "SOURCE_DATE_EPOCH"
|
2022-05-10 18:11:37 +08:00
|
|
|
)
|
|
|
|
|
2021-10-18 13:51:51 +08:00
|
|
|
// StageMountDetails holds the Stage/Image mountpoint returned by StageExecutor
|
|
|
|
// StageExecutor has ability to mount stages/images in current context and
|
|
|
|
// automatically clean them up.
|
|
|
|
type StageMountDetails struct {
|
2025-01-07 02:47:31 +08:00
|
|
|
DidExecute bool // true if this is a freshly-executed stage, or an image, possibly from a non-local cache
|
|
|
|
IsStage bool // true if the mountpoint is a stage's rootfs
|
|
|
|
IsImage bool // true if the mountpoint is an image's rootfs
|
|
|
|
IsAdditionalBuildContext bool // true if the mountpoint is an additional build context
|
|
|
|
MountPoint string // mountpoint of the stage or image's root directory or path of the additional build context
|
2021-10-18 13:51:51 +08:00
|
|
|
}
|