Idein / dockworker

Docker daemon API client in Rust
61 stars 35 forks source link

fix containers/{id}/stats #158

Closed raefko closed 3 months ago

raefko commented 6 months ago

After some test i found that

curl --unix-socket /var/run/docker.sock http:/v1.24/containers/ad31ebf6f8b1c13e9fd725eaefc53225defe5bc7cd4dffdff486dc5be673a64f/stats\?stream

disable stream and enable one-shot and that

curl --unix-socket /var/run/docker.sock http:/v1.24/containers/ad31ebf6f8b1c13e9fd725eaefc53225defe5bc7cd4dffdff486dc5be673a64f/stats\?one-shot

do the opposite, so I fixed the endpoint

eldesh commented 3 months ago

As of version 1.24, the one-shot parameter was not introduced. Please check with version 1.41 or later. https://docs.docker.com/engine/api/v1.24/#get-container-stats-based-on-resource-usage

notion-workspace[bot] commented 3 months ago

dockworker: stats のPR対応