mirror of
https://github.com/containers/podman.git
synced 2025-11-30 18:18:18 +08:00
Include an explicit container state check. Otherwise the containers/stats endpoint will return all-zero stats for a stopped container even when in non-streaming mode, which breaks some consumers of the API, particularly nomad's podman driver. Implement the interface by just returning the number of host CPUs. A bit more sophisticated would be to fetch the jail's cpuset, but it's not very important for now. Signed-off-by: Mark Johnston <mark.johnston@klarasystems.com>
4.5 KiB
4.5 KiB