- Command Reference
- Build the image
- Build the container
- Remove all images with names that contain
flask
- Remove all containers with names that contain
flask
- See what's running
docker build -t flask-image .
docker run -p 5000:5000 --rm --name flask-container flask-image
Remove all images with names that contain flask
docker images -a | grep "flask" | awk '{print $3}' | xargs docker rmi
Remove all containers with names that contain flask
docker ps -a | grep "flask" | awk '{print $3}' | xargs docker rmi
docker ps --format '{{.Names}}'