[Docker] Container & image (docker run)

image: stopped container

 

Run a container:

docker run -d --name web -p 80:8080 nigelpoulton/pluralsight-docker-ci

Run in background.

Stop it:

docker stop web

Start it again:

docker start web

 

 

Stop all the running containers:

docker stop $(docker ps -aq)

 

Remove all the containers:

docker rm $(docker ps -aq)

 

remove all images:

docker rmi $(docker images -q)

 

posted @ 2017-03-08 03:23  Zhentiw  阅读(273)  评论(0)    收藏  举报