Podman API service returns incorrect JSON (missing Mounts
value) for Container List call
#12734
Labels
kind/bug
Categorizes issue or PR as related to a bug.
locked - please file new issue/PR
Assist humans wanting to comment on an old issue or PR with locked comments.
Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)
/kind bug
Description
The Podman API service returns incorrect JSON for a Docker Container List call: specifically, the
Mounts
property isnull
but should be populated with an object representing any mountpoints.Steps to reproduce the issue:
Launch a Podman container i.e.
podman run --name test -v /opt:/opt alpine:latest ash -c 'sleep infinity'
Launch the Podman API service i.e.
podman system service --time=0 unix:///tmp/podman.sock
Call the Docker Container List API i.e.
curl -s --unix-socket /tmp/podman.sock -H "Content-Type: application/json" -X GET "http:/v1.40/containers/json?all=true"
Launch an equivalent Docker container i.e.
docker run --name test -v /opt:/opt alpine:latest ash -c 'sleep infinity'
Call the Docker Container List API i.e.
curl -s --unix-socket /var/run/docker.sock -H "Content-Type: application/json" -X GET "http:/v1.40/containers/json?all=true"
Compare the results
Describe the results you received:
The Podman API returns JSON contains
"Mounts": null
.Describe the results you expected:
i.e.
(This value matches that returned by the Podman API for the Container Inspect call i.e.
curl -s --unix-socket /tmp/podman.sock -H "Content-Type: application/json" -X GET "http:/v1.40/containers/test/json"
).Additional information you deem important (e.g. issue happens only occasionally):
Happens consistently.
Output of
podman version
:Output of
podman info --debug
:Package info (e.g. output of
rpm -q podman
orapt list podman
):Have you tested with the latest version of Podman and have you checked the Podman Troubleshooting Guide? (https://github.com/containers/podman/blob/master/troubleshooting.md)
Yes. I'm running Debian Sid version 3.4.4, which matches the latest release. The issue also affected Podman 3.0.1 in Debian Bullseye.
I've checked the troubleshooting guide.
Additional environment details (AWS, VirtualBox, physical, etc.):
Running vanilla Debian Bullseye on a KVM VM with Debian Sid Podman v3.4.4.
The text was updated successfully, but these errors were encountered: