mirror of https://github.com/containers/podman.git
Merge pull request #17506 from rhatdan/build
Allow specification of podman --remote build -f -
This commit is contained in:
commit
83757ccb55
|
@ -218,7 +218,11 @@ func build(cmd *cobra.Command, args []string) error {
|
|||
var containerFiles []string
|
||||
for _, f := range buildOpts.File {
|
||||
if f == "-" {
|
||||
if len(args) == 0 {
|
||||
args = append(args, "-")
|
||||
} else {
|
||||
containerFiles = append(containerFiles, "/dev/stdin")
|
||||
}
|
||||
} else {
|
||||
containerFiles = append(containerFiles, f)
|
||||
}
|
||||
|
|
|
@ -101,6 +101,12 @@ EOF
|
|||
is "$output" "$rand_content" "reading generated file in image"
|
||||
|
||||
run_podman rmi -f build_test
|
||||
|
||||
# Now try without specifying a context dir
|
||||
run_podman build -t build_test -f - < $containerfile
|
||||
is "$output" ".*COMMIT" "COMMIT seen in log"
|
||||
|
||||
run_podman rmi -f build_test
|
||||
}
|
||||
|
||||
@test "podman build - global runtime flags test" {
|
||||
|
|
Loading…
Reference in New Issue