Example | Description |
---|---|
docker stop -f $(docker ps -a -q) |
Stopping all containers |
docker rm -f $(docker ps -a -q) |
Removing all containers |
docker rmi -f $(docker images -q) |
Removing all images |
Miscellaneous
Batch clean
Registry commands
Login to a Registry
$ docker login
$ docker login localhost:8080
Logout from a Registry
$ docker logout
$ docker logout localhost:8080
Searching an Image
$ docker search nginx
$ docker search nginx --stars=3 --no-trunc busybox
Pulling an Image
$ docker pull nginx
$ docker pull eon01/nginx localhost:5000/myadmin/nginx
Pushing an Image
$ docker push eon01/nginx
$ docker push eon01/nginx localhost:5000/myadmin/nginx
Docker Hub
Docker Syntax | Description |
---|---|
docker search search_word |
Search docker hub for images. |
docker pull user/image |
Downloads an image from docker hub. |
docker login |
Authenticate to docker hub |
docker push user/image |
Uploads an image to docker hub. |
Comments