mirror of
https://github.com/containers/podman.git
synced 2025-09-26 16:25:00 +08:00
Bump to Buildah v1.11.5
Bump to Buildah v1.11.5. Most notably changes to the podman build `--pull` functionality. `--pull=true` and `--pull=false` now work as Docker does, `--pull-never` added to supply the functionality of the old `--pull=false`. Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
This commit is contained in:
22
vendor/github.com/containers/buildah/pkg/cli/common.go
generated
vendored
22
vendor/github.com/containers/buildah/pkg/cli/common.go
generated
vendored
@ -63,6 +63,7 @@ type BudResults struct {
|
||||
Platform string
|
||||
Pull bool
|
||||
PullAlways bool
|
||||
PullNever bool
|
||||
Quiet bool
|
||||
Rm bool
|
||||
Runtime string
|
||||
@ -159,8 +160,9 @@ func GetBudFlags(flags *BudResults) pflag.FlagSet {
|
||||
fs.StringVar(&flags.Logfile, "logfile", "", "log to `file` instead of stdout/stderr")
|
||||
fs.IntVar(&flags.Loglevel, "loglevel", 0, "adjust logging level (range from -2 to 3)")
|
||||
fs.StringVar(&flags.Platform, "platform", "", "CLI compatibility: no action or effect")
|
||||
fs.BoolVar(&flags.Pull, "pull", true, "pull the image if not present")
|
||||
fs.BoolVar(&flags.PullAlways, "pull-always", false, "pull the image, even if a version is present")
|
||||
fs.BoolVar(&flags.Pull, "pull", true, "pull the image from the registry if newer or not present in store, if false, only pull the image if not present")
|
||||
fs.BoolVar(&flags.PullAlways, "pull-always", false, "pull the image even if the named image is present in store")
|
||||
fs.BoolVar(&flags.PullNever, "pull-never", false, "do not pull the image, use the image present in store if available")
|
||||
fs.BoolVarP(&flags.Quiet, "quiet", "q", false, "refrain from announcing build instructions and image read/write progress")
|
||||
fs.BoolVar(&flags.Rm, "rm", true, "Remove intermediate containers after a successful build")
|
||||
// "runtime" definition moved to avoid name collision in podman build. Defined in cmd/buildah/bud.go.
|
||||
@ -265,9 +267,15 @@ func VerifyFlagsArgsOrder(args []string) error {
|
||||
}
|
||||
|
||||
func GetDefaultAuthFile() string {
|
||||
authfile := os.Getenv("REGISTRY_AUTH_FILE")
|
||||
if authfile != "" {
|
||||
return authfile
|
||||
}
|
||||
return ""
|
||||
return os.Getenv("REGISTRY_AUTH_FILE")
|
||||
}
|
||||
|
||||
func CheckAuthFile(authfile string) error {
|
||||
if authfile == "" {
|
||||
return nil
|
||||
}
|
||||
if _, err := os.Stat(authfile); err != nil {
|
||||
return errors.Wrapf(err, "error checking authfile path %s", authfile)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user