Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Docker disk usage endpoint at /api/system/docker/disk #7

Merged
merged 4 commits into from
Apr 18, 2024

Conversation

iamkubi
Copy link
Contributor

@iamkubi iamkubi commented Apr 17, 2024

/api/system/docker/disk endpoint provides disk utilization of the docker daemon. Example output:

$ curl localhost:8080/api/system/docker/disk
{"containers_size": "163.4MB", "images_total":4,"images_active":2,"images_size":"181MB","build_cache_size":0}

@iamkubi
Copy link
Contributor Author

iamkubi commented Apr 17, 2024

Added /api/system/docker/image/prune

$ curl -X DELETE -H "Authorization: Bearer ${PELICAN_TOKEN}" localhost:8080/api/system/docker/image/prune
{"ImagesDeleted":[{"Untagged":"ghcr.io/parkervcp/yolks@sha256:bf028a2e41311b30d760a68033e09e9b8258320d10e5639087807f5827474252"},{"Deleted":"sha256:7f9cc1ff412f6c20737d7c796fce106f6d37adaa86260a4f11e7f8017822baa0"},{"Deleted":"sha256:5f5ceb2cd2bc959e2a5458b4d08dfe4681f2eae29caaf655371d377a1a85d82e"},{"Deleted":"sha256:82a9fed77876af1a992506b347530e74b30b467bb39bb1a6185318c1e6ebff08"},{"Deleted":"sha256:82769d9c11f2e7f202c823891f28b006869778ee4a25e3b0797af947de145941"},{"Deleted":"sha256:001ebb1c2b548d928c918cc473aa92cafee19637bcf08cd1cf50fe5dac52640a"},{"Deleted":"sha256:6530bcb1e768ca23eb817d9297227e962627df8a49b720ab6e3516aae361e798"}],
"SpaceReclaimed":61837573}

@iamkubi iamkubi merged commit cd546ba into main Apr 18, 2024
6 checks passed
@iamkubi iamkubi deleted the docker_stats branch April 18, 2024 03:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant