diff options
author | Michael Scherer <misc@redhat.com> | 2021-11-12 12:56:57 +0100 |
---|---|---|
committer | Michael Scherer <misc@redhat.com> | 2021-11-12 14:18:26 +0100 |
commit | b1c002342426fac0770e4a7d07a57018964724dd (patch) | |
tree | 8da768ae6616ba05f787eadb0861ef4c405a29e6 /pkg/api | |
parent | 92da8682b3977a6ef57a6f73dde2f2aef6186d19 (diff) | |
download | podman-b1c002342426fac0770e4a7d07a57018964724dd.tar.gz podman-b1c002342426fac0770e4a7d07a57018964724dd.tar.bz2 podman-b1c002342426fac0770e4a7d07a57018964724dd.zip |
Always create working directory when using compat API
Docker/Moby always create the working directory, and some tools
rely on that behavior (example, woodpecker/drone).
Fixes #11842
Signed-off-by: Michael Scherer <misc@redhat.com>
Diffstat (limited to 'pkg/api')
-rw-r--r-- | pkg/api/handlers/compat/containers_create.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/pkg/api/handlers/compat/containers_create.go b/pkg/api/handlers/compat/containers_create.go index 94d20a04a..1e175d664 100644 --- a/pkg/api/handlers/compat/containers_create.go +++ b/pkg/api/handlers/compat/containers_create.go @@ -86,6 +86,8 @@ func CreateContainer(w http.ResponseWriter, r *http.Request) { utils.Error(w, "Something went wrong.", http.StatusInternalServerError, errors.Wrap(err, "fill out specgen")) return } + // moby always create the working directory + sg.CreateWorkingDir = true ic := abi.ContainerEngine{Libpod: runtime} report, err := ic.ContainerCreate(r.Context(), sg) |