- docker [ info | version]
- docker [ run | start | stop | restart | kill | rm | pause | unpause ]
- docker [ ps | inspect | exec | logs | export | import | port ]
- docker [ commit | cp | diff ]
- docker [ images | rmi | tag | build | history | save | import ]
- docker [ login | pull | push | search ]
Images
$ docker search hello-world
$ docker images
$ docker image ls
$ docker image list
$ docker pull hello-world
$ docker pull hello-world:latest
$ docker pull --all-tags hello-world
$ docker rmi -f image-id
$ docker rmi hello-world:latest
$ docker images -a | grep "hello-world" | awk '{print $3}' | xargs docker rmi
$ docker rmi $(docker images -a -q)
$ docker images hello-world:* | xargs docker rmi
$ docker run --rm hello-world
$ docker ps -a -f status=exited
$ docker rm $(docker ps -a -f status=exited -q)
$ docker ps -a -f status=exited -f status=created
$ docker rm $(docker ps -a -f status=exited -f status=created -q)