Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # build with docker compose
- docker-compose build
- # run with docker-compose and open bash
- docker-compose run --rm <image> /bin/bash
- # Stop all Docker containers
- docker stop $(docker ps -a -q)
- # DANGER ZONE
- # This will remove:
- # - all stopped containers
- # - all networks not used by at least one container
- # - all dangling images
- # - all dangling build cache
- docker system prune
- # DANGER: Removes all docker containers
- docker rm $(docker ps -a -q)
- # DANGER: Removes all images, even those images that are referenced in repositories
- docker rmi $(docker images -q) --force
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement