1、开通阿里云ACR
2、在ACR 中创建命名空间
3、本地安装docker
4、登录到
开通ACR,需要配置访问凭证
[root@master ~]# docker login --username=***lb registry.cn-beijing.aliyuncs.com
Password:
5、给镜像打标签文章来源:https://www.toymoban.com/news/detail-665722.html
[root@master ~]# docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
prom/prometheus latest 3b907f5313b7 3 weeks ago 245MB
rancher/rancher latest 81ee0878ffcd 7 weeks ago 1.73GB
[root@master ~]# docker tag 3b907f5313b7 registry.cn-beijing.aliyuncs.com/huangliangbin1/prometheus:latest
6、上传镜像文章来源地址https://www.toymoban.com/news/detail-665722.html
[root@master ~]# docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
prom/prometheus latest 3b907f5313b7 3 weeks ago 245MB
registry.cn-beijing.aliyuncs.com/huangliangbin1/prometheus latest 3b907f5313b7 3 weeks ago 245MB
rancher/rancher latest 81ee0878ffcd 7 weeks ago 1.73GB
[root@master ~]# docker push registry.cn-beijing.aliyuncs.com/huangliangbin1/prometheus:latest
The push refers to repository [registry.cn-beijing.aliyuncs.com/huangliangbin1/prometheus]
3930de501da9: Pushed
d12fff6feee7: Pushed
到了这里,关于上传镜像到阿里云的ACR的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!