Docker系类(25)- 发布镜像到DockerHub
2024-09-08 08:03:11
# step-1 注册账号
https://hub.docker.com/
# step-2 在服务器尚提交我们的镜像
[root@localhost WEB-INF]# docker login --help
Usage: docker login [OPTIONS] [SERVER]
Log in to a Docker registry.
If no server is specified, the default is defined by the daemon.
Options:
-p, --password string Password
--password-stdin Take the password from stdin
-u, --username string Username
[root@localhost WEB-INF]# docker login -u gelaotou
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
# step-3 在服务器尚提交我们的镜像
[root@localhost WEB-INF]# docker push diytomcat
Using default tag: latest
The push refers to repository [docker.io/library/diytomcat]
7eac4b6854fa: Preparing
3dd2e24e54bc: Preparing
fc06d55fbf5f: Preparing
denied: requested access to the resource is denied
#提交报错处理,因为没有版本号
[root@localhost WEB-INF]# docker tag c18dbee63b6a gelaotou/diytomcat:1.0
[root@localhost WEB-INF]# docker push gelaotou/diytomcat:1.0
The push refers to repository [docker.io/gelaotou/diytomcat]
7eac4b6854fa: Pushed
3dd2e24e54bc: Pushed
fc06d55fbf5f: Pushed
3f2369e46cc3: Pushed
2653d992f4ef: Pushed
1.0: digest: sha256:60c0b82f8bbab61933658c71ea44f27905fc76308c351ba91908223be0764b90 size: 1373
最新文章
- JS初级-作用域
- [js开源组件开发]js文本框计数组件
- android 回调函数
- 58. Length of Last Word
- [反汇编练习] 160个CrackMe之019
- spring自定义注解
- 如何在 OS X Yosemite 中安装 Java
- apache tomcat 集群! (转)
- node源码详解(四) —— js代码如何调用C++的函数
- PHP基础入门(二)【PHP函数基础】
- 3.python元组与列表
- Java解析XML与生成XML文件
- 戏说程序猿之cannot find the object
- 【转】ASP.NET MVC实现权限控制
- APP-9-文字识别-车牌识别
- ibatis.net:惯用法
- django CBV模式下如何去掉csrf验证
- [翻译] Python 3.5中async/await的工作机制
- 【UOJ #131】【NOI 2015】品酒大会
- 设计模式之简单工厂模式(Simply Factory)摘录