建立aliyun映象倉庫
阿新 • • 發佈:2022-04-03
建立aliyun映象倉庫
登陸地址:cr.console.aliyun.com
命令列登陸倉庫
[root@centos7 ~]#docker login --username=xp018970 registry.cn-beijing.aliyuncs.com Password: WARNING! Your password will be stored unencrypted in /root/.docker/config.json. Configure a credential helper to remove this warning. See https://docs.docker.com/engine/reference/commandline/login/#credentials-store Login Succeeded
檢視當前映象
#docker images REPOSITORY TAG IMAGE ID CREATED SIZE 172.18.141.24/linux35/centos v1 9f38484d220f 2 weeks ago 202MB 172.18.142.3/linux35/centos v1 9f38484d220f 2 weeks ago 202MB centos latest 9f38484d220f 2 weeks ago 202MB 172.18.142.3/linux35/ubuntu v1 94e814e2efa8 3 weeks ago 88.9MB
映象打tag
#docker tag centos:latest registry.cn-beijing.aliyuncs.com/xp018970/centos:v1
映象上傳到倉庫
#docker push registry.cn-beijing.aliyuncs.com/xp018970/centos:v1 The push refers to repository [registry.cn-beijing.aliyuncs.com/xp018970/centos] d69483a6face: Pushed v1: digest: sha256:ca58fe458b8d94bc6e3072f1cfbd334855858e05e1fd633aa07cf7f82b048e66 size: 529
驗證上傳的映象
下載映象
#docker pull registry.cn-beijing.aliyuncs.com/xp018970/centos:v1 v1: Pulling from xp018970/centos Digest: sha256:ca58fe458b8d94bc6e3072f1cfbd334855858e05e1fd633aa07cf7f82b048e66 Status: Image is up to date for registry.cn-beijing.aliyuncs.com/xp018970/centos:v1
FYI:https://note.youdao.com/ynoteshare/index.html?id=1890f2ba9e6dd5f6a812767f375cb2c0&type=note&_time=1648971628836