How to stop all containers in Docker?

To stop all Docker containers, you can use the following command:

  1. Show only the container IDs of running docker containers.
  2. stop the docker container
docker stop $(docker ps -q)

This will stop all running containers.

Leave a Reply 0

Your email address will not be published. Required fields are marked *


广告
Closing in 10 seconds
bannerAds