4-Docker命令之docker tag

嚴華  论坛元老 | 2024-6-22 13:05:55 | 显示全部楼层 | 阅读模式
打印 上一主题 下一主题

主题 1050|帖子 1050|积分 3150

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?立即注册

x
1.docker tag先容

docker tag命令是用来给docker镜像打标签
2.docker tag用法

docker tag SOURCE_IMAGE[:TAG] TARGET_IMAGE[:TAG]
  1. [root@centos79 ~]# docker tag --help
  2. Usage:  docker tag SOURCE_IMAGE[:TAG] TARGET_IMAGE[:TAG]
  3. Create a tag TARGET_IMAGE that refers to SOURCE_IMAGE
  4. Aliases:
  5.   docker image tag, docker tag
  6. [root@centos79 ~]#
复制代码
3.实例

3.1.docker镜像打标签

命令:
docker tag nginx:latest nginx:1.0
  1. [root@centos79 ~]# docker images | grep nginx
  2. nginx                                latest        605c77e624dd   23 months ago   141MB
  3. [root@centos79 ~]# docker tag nginx:latest nginx:1.0
  4. [root@centos79 ~]# docker images | grep nginx
  5. nginx                                1.0           605c77e624dd   23 months ago   141MB
  6. nginx                                latest        605c77e624dd   23 months ago   141MB
  7. [root@centos79 ~]#
复制代码


免责声明:如果侵犯了您的权益,请联系站长,我们会及时删除侵权内容,谢谢合作!更多信息从访问主页:qidao123.com:ToB企服之家,中国第一个企服评测及商务社交产业平台。
回复

使用道具 举报

0 个回复

倒序浏览

快速回复

您需要登录后才可以回帖 登录 or 立即注册

本版积分规则

嚴華

论坛元老
这个人很懒什么都没写!
快速回复 返回顶部 返回列表