Last active
June 14, 2024 14:31
-
-
Save r0mdau/7e5100ff175acf954f05e5124c3d3b7d to your computer and use it in GitHub Desktop.
Match docker overlay directory with container name
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
df -hi | |
apt install jq | |
cd /var/lib/docker/overlay2/ | |
find . -xdev -type f | cut -d "/" -f 2 | sort | uniq -c | sort -n | |
docker inspect $(docker ps -qa) | jq -r 'map([.Name, .GraphDriver.Data.MergedDir]) | .[] | "\(.[0])\t\(.[1])"' | |
docker ps | |
docker images |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Excelent, thank you for shared