docker rmi命令是用来删除本地一个或多个docker镜像
docker rmi [参数] IMAGE [IMAGE...]
[root@centos79 ~]# docker rmi --help
Usage: docker rmi [OPTIONS] IMAGE [IMAGE...]
Remove one or more images
Aliases:
docker image rm, docker image remove, docker rmi
Options:
-f, --force Force removal of the image
--no-prune Do not delete untagged parents
[root@centos79 ~]#
docker rmi centos:centos7
[root@centos79 ~]# docker images | grep eeb6
centos centos7 eeb6ee3f44bd 2 years ago 204MB
[root@centos79 ~]# docker rmi centos:centos7
Untagged: centos:centos7
Untagged: centos@sha256:9d4bcbbb213dfd745b58be38b13b996ebb5ac315fe75711bd618426a630e0987
Deleted: sha256:eeb6ee3f44bd0b5103bb561b4c16bcb82328cfe5809ab675bb17ab3a16c517c9
[root@centos79 ~]# docker images | grep e