Skip to content

Instantly share code, notes, and snippets.

@Chever-John
Last active April 15, 2022 01:05
Show Gist options
  • Save Chever-John/43d564c85e63f01df9fe04cbf878c79e to your computer and use it in GitHub Desktop.
Save Chever-John/43d564c85e63f01df9fe04cbf878c79e to your computer and use it in GitHub Desktop.
#!/usr/bin/env bash
docker rm $(docker ps -qf 'status=exited')
docker rmi $(docker images -qf 'dangling=true')
docker rmi $(docker images -a)
docker rmi $(docker images -a) -f
docker volume rm $(docker volume ls -qf 'dangling=true')
sudo docker system df
sudo docker volume prune
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment