1. 查看docker信息(version、info)
查看docker版本
docker version
显示docker系统的信息
docker info
2. 对image的操作(search、pull、images、rmi、history)
检索image
docker search image_name
下载image
docker pull image_name
列出镜像列表; -a, --all=false Show all images; --no-trunc=false Don't truncate output; -q, --quiet=false Only show numeric IDs
docker images
删除一个或者多个镜像; -f, --force=false Force; --no-prune=false Do not delete untagged parents
docker rmi image_name
显示一个镜像的历史; --no-trunc=false Don't truncate output; -q, --quiet=false Only show numeric IDs
docker history image_name
3. 启动容器(run)
docker容器可以理解为在沙盒中运行的进程。这个沙盒包含了该进程运行所必须的资源,包括文件系统、系统类库、shell 环境等等。但这个沙盒默认是不会运行任何程序的