docker 基本命令

 docker search learn/tutorial  搜索镜像

docker pull learn/tutorial  下载镜像

docker run learn/tutorial echo "helloworld"   允许镜像

 

docker run learn/tutorial apt-get install -t ping   在learn/tutorial 安装新程序Ping

docker ps -l  查看容器的id                           docker commit 172b learn/ping 提交   (其中172b为id前4位)

 

在新的镜像中使用ping   docker run learn/ping ping www.baidu.com 

检查允许中的镜像   docker inspect  efe 

发布镜像 docker push learn/ping

 

来源:http://www.docker.org.cn/book/docker/docker-push-image-13.html

posted @ 2018-10-16 14:41  8394971  阅读(188)  评论(0编辑  收藏  举报