Skip to content

Instantly share code, notes, and snippets.

@osiyuk
Created September 1, 2017 02:14
Show Gist options
  • Star 11 You must be signed in to star a gist
  • Fork 5 You must be signed in to fork a gist
  • Save osiyuk/12b223532eb8ac21b25283159c3147b1 to your computer and use it in GitHub Desktop.
Save osiyuk/12b223532eb8ac21b25283159c3147b1 to your computer and use it in GitHub Desktop.
free up disk space after docker garbage
#!/bin/bash
GARBAGE="/var/lib/docker/aufs/diff"
du -hd 1 $GARBAGE | sort -hrk 1 | head -25
find $GARBAGE -maxdepth 1 -name *-removing -exec rm -rf '{}' \;
@flyer103
Copy link

flyer103 commented Sep 1, 2017

docker system prune may be a simple solution :D

@osiyuk
Copy link
Author

osiyuk commented Sep 1, 2017

@flyer103 simple, but not working... it only marks diffs with suffix -removing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment