1. 登录镜像仓库
# docker login registry.akulaku.com Username: chenfj 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
2. 对镜像进行打tag
## 语法 docker tag SOURCE_IMAGE[:TAG] registry.akulaku.com/sre/REPOSITORY[:TAG] ## docker tag nginx:1.7.9 registry.akulaku.com/sre/nginx:1.7.9
3. 推送镜像到仓库
## 语法 ## docker push registry.akulaku.com/sre/REPOSITORY[:TAG] # docker push registry.akulaku.com/sre/nginx:1.7.9 The push refers to repository [registry.akulaku.com/sre/nginx] 5f70bf18a086: Pushed 4b26ab29a475: Pushed ccb1d68e3fb7: Pushed e387107e2065: Pushed 63bf84221cce: Pushed e02dce553481: Pushed dea2e4984e29: Pushed 1.7.9: digest: sha256:b1f5935eb2e9e2ae89c0b3e2e148c19068d91ca502e857052f14db230443e4c2 size: 3012