docker 基本命令

时间:2020-07-20 00:03:11   收藏:0   阅读:105

帮助命令

docker version   #显示docker的版本信息
docker info        #显示docker的系统信息,包括镜像和容器的数量
docker 命令 --help   #万能命令

 

镜像命名

docker images 查看所有本地的主机上的镜像

[root@localhost ~]# docker images
REPOSITORY          TAG                 IMAGE ID            CREATED             SIZE
hello-world         latest              bf756fb1ae65        6 months ago        13.3kB

解释
REPOSITORY  镜像的仓库源
TAG      镜像的标签
IMAGE ID   镜像的id
CREATED    镜像的创建时间
SIZE      镜像的大小

-a, --all    #列出所有镜像
-q, --quiet #只显示镜像的id

docker search  搜索镜像

mysql                             MySQL is a widely used, open-source relation…   9746                [OK]                
mariadb                           MariaDB is a community-developed fork of MyS…   3558                [OK] 

#可选项
--filter=STARS=3000  #过滤stars等于3000的

docker pull  下载镜像

 

评论(0
© 2014 mamicode.com 版权所有 京ICP备13008772号-2  联系我们:gaon5@hotmail.com
迷上了代码!