Skip to content

Instantly share code, notes, and snippets.

@ziyoung
Last active April 23, 2019 10:17
Show Gist options
  • Save ziyoung/d762122c57079f521d4b74cb8a1e3edb to your computer and use it in GitHub Desktop.
Save ziyoung/d762122c57079f521d4b74cb8a1e3edb to your computer and use it in GitHub Desktop.
remove none docker image
# 下面的这个命令更简洁一些,docker image ls -f "dangling=true" -q
IMAGES=`docker images -f "dangling=true" -q`
docker rmi $IMAGES
# 更为简洁的命令
docker rmi -f $(docker images --filter "dangling=true" -q --no-trunc)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment