当前位置:首页 > 技术杂谈 > 正文

docker修改镜像名称以及保存镜像文件

2024-03-31 技术杂谈

1、修改镜像名

[[email protected] ~]# docker images
REPOSITORY                  TAG                 IMAGE ID            CREATED             SIZE
absolutapps/oracle-12c-ee   latest              ad9bdfc002e7        3 years ago         6.12GB
[[email protected] ~]# docker tag ad9bdfc002e7 oracle-12c-ee:latest
[[email protected] ~]# docker images
REPOSITORY                  TAG                 IMAGE ID            CREATED             SIZE
absolutapps/oracle-12c-ee   latest              ad9bdfc002e7        3 years ago         6.12GB
oracle-12c-ee               latest              ad9bdfc002e7        3 years ago         6.12GB

2、保存镜像,便于镜像转移

docker save ad9bdfc002e7 -o /home/docker_oracle-12c-ee.tar

 

温馨提示: 本文由Jm博客推荐,转载请保留链接: https://www.jmwww.net/a/17423.html