首页 > 其他 > 详细

docker

时间:2020-07-21 21:21:28      阅读:58      评论:0      收藏:0      [点我收藏+]

#Concept

Image: An image is a read-only template with instructions for creating a Docker container.

Container:A container is a runnable instance of an image.

Registries: A Docker registry stores Docker images. Docker Hub is a public registry that anyone can use, and Docker is configured to look for images on Docker Hub by default. 

 技术分享图片

 

 

#list the images

docker images

#list the containers

docker ps -a

#run a image 

docker run -it ubuntu:latest \bin\bash

exit : quit the running ubuntu

using docker ps -a, you can see the container running, later you can docker start -i container_id

#share folder

docker run -it -v ~/share-docker:/share ubuntu 
 
#docker images location
/var/lib/docker/ 
 
#save a image to file
docker image save ubutun-aaa -o ~/docker/newimage

docker

原文:https://www.cnblogs.com/zjbfvfv/p/13355834.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!