• 查看镜像
docker image ls
docker image --help
docker images
docker images --help
• 默认使用的仓库地址
• 公共仓库地址,注册个人账户
https://hub.docker.com/
docker login docker.io
• 关于alpine
https://alpinelinux.org/about/
Alpine Linux is an independent, non-commercial, general purpose Linux distribution
designed for power users who appreciate security, simplicity and resource efficiency.
Alpine Linux is a security-oriented, lightweight Linux distribution based on musl libc and busybox .
• 在官方仓库中搜索镜像 alpine
docker search alpine
docker inspect alpine:3.12.0
• 拉取镜像到本地
docker pull fjzcau/alpine:3.11.6.20200615
docker pull alpine:3.11.6
• 查看已拉取的镜像
• 打标签
docker tag f70734b6a266 fjzcau/alpine:3.11.6.20200615
• 将本地镜像push到远端仓库
docker push fjzcau/alpine:3.11.6.20200615
• 登陆docker hub
docker login docker.io
• 登陆docker-hub站点查看镜像
• 打标签
docker tag alpine:3.11.6 alpine:3.11.6-bak
• 删除本地镜像 -tag
docker image rm alpine:3.11.6
• 删除本地镜像 -ID
docker image rm f70734b6a266
[root@master01 ~]# docker image rm f70734b6a266
Error response from daemon: conflict: unable to delete f70734b6a266 (must be forced) - image is referenced in multiple repositories
• 强制删除镜像 -ID
docker image rm -f f70734b6a266
或
docker rmi -f f70734b6a266
• alpine镜像相关的tag全部被删除
如果觉得我的文章对您有用,请点赞。您的支持将鼓励我继续创作!
赞1
添加新评论0 条评论