diff options
author | cdoern <cdoern@redhat.com> | 2022-01-13 16:41:13 -0500 |
---|---|---|
committer | cdoern <cdoern@redhat.com> | 2022-01-13 16:44:10 -0500 |
commit | bf3734ad53c6ad212c56730350e6265bf8278913 (patch) | |
tree | b386af5e3f2a4671be1349bebdc4ce1af1d5b365 /cmd/podman/images | |
parent | 2c510146aa03c74fb00a15bcf81c62b14df9c7ea (diff) | |
download | podman-bf3734ad53c6ad212c56730350e6265bf8278913.tar.gz podman-bf3734ad53c6ad212c56730350e6265bf8278913.tar.bz2 podman-bf3734ad53c6ad212c56730350e6265bf8278913.zip |
Podman Build use absolute filepath
podman build always finds the abs path but was never using it for the containerfile path. This
was causing the remote client to be given a relative path that does not exist. Switch to evaluating and using absolute paths only.
resolves #12841
Signed-off-by: cdoern <cdoern@redhat.com>
Diffstat (limited to 'cmd/podman/images')
-rw-r--r-- | cmd/podman/images/build.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd/podman/images/build.go b/cmd/podman/images/build.go index 606c18aae..6fc73eb64 100644 --- a/cmd/podman/images/build.go +++ b/cmd/podman/images/build.go @@ -257,6 +257,7 @@ func build(cmd *cobra.Command, args []string) error { return errors.Wrapf(err, "error determining path to file %q", containerFiles[i]) } contextDir = filepath.Dir(absFile) + containerFiles[i] = absFile break } } @@ -289,7 +290,6 @@ func build(cmd *cobra.Command, args []string) error { if err != nil { return err } - report, err := registry.ImageEngine().Build(registry.GetContext(), containerFiles, *apiBuildOpts) if err != nil { |