build docker镜像时发送到deamo的内容过大问题
来源:互联网 发布:道路设计常用数据手册 编辑:程序博客网 时间:2024/04/29 07:50
当使用Dockerfile Build镜像时,发现发送到Daemo的内容过大
build image:q_build/javaweb:20150910174642<span style="padding: 0px;"><span style="padding: 0px; color: rgb(255, 0, 0);">Sending build context to Docker daemon 4.768 GB</span></span>Sending build context to Docker daemon Step 0 : FROM 192.168.100.123:5000/q_basic/javaweb:1.0 ---> 0aab72ab2945Step 1 : MAINTAINER tyleryan <156926528@qq.com> ---> Running in 177026c30954 ---> 3cc2be8f728dRemoving intermediate container 177026c30954Step 2 : ADD monitor.war /usr/local/tomcat/webapps/ ---> b8b56342b691Removing intermediate container c0108ff358f3Step 3 : EXPOSE 8080 ---> Running in 451fa4de3e21 ---> 13f7293f7ffeRemoving intermediate container 451fa4de3e21Successfully built 13f7293f7ffedelete locally build docker images:q_build/<span id="0_nwp" style="padding: 0px; width: auto; height: auto; float: none;"><a target=_blank id="0_nwl" href="http://cpro.baidu.com/cpro/ui/uijs.php?adclass=0&app_id=0&c=news&cf=1001&ch=0&di=128&fv=20&is_app=0&jk=5fc23cd07d5ff9b3&k=javaweb&k0=javaweb&kdi0=0&luki=4&mcpm=0&n=10&p=baidu&q=65035100_cpr&rb=0&rs=1&seller_id=1&sid=b3f95f7dd03cc25f&ssp2=1&stid=9&t=tpclicked3_hc&td=1836545&tu=u1836545&u=http%3A%2F%2Fwww%2Ebubuko%2Ecom%2Finfodetail%2D1089142%2Ehtml&urlid=0" target="_blank" mpid="0" style="padding: 0px; color: rgb(51, 51, 51); text-decoration: none;"><span style="padding: 0px; color: rgb(0, 0, 255); width: auto; height: auto;">javaweb</span></a></span>:20150910174642
但是我们的Dokerfile 非常简单,那么这些多出来的内容是从哪里来的呢。
查阅资料后,
发现Docker Client会默认发送Dockerfile同级目录下的所有文件到Dockerdaemon中。
?
解决办法有两种:
1.使用.dockerignore文件,设置黑名单,该文件包含的目录不会被发送到Docker daemon中
2.将Dockerfile迁移后其他目录中执行。
0 0
- build docker镜像时发送到deamo的内容过大问题
- 解决Docker build时 Sending build context to Docker daemon 过大的问题
- linux的deamo函数
- 解决vue-cli npm run build之后vendor.js文件过大的问题
- docker build 命令的问题纠结三天了
- 内容共享 之 发送内容到其他的APP
- ueditor 上传的图片在内容里显示的尺寸过大的问题
- 解决post内容过大后台接收参数为NULL的问题
- build.gradle的内容
- UE4 缓存过大的问题
- post数据过大的问题
- docker的一些内容
- 发送带html标记的内容到后台
- 的发送到发送到发送到
- WCF 通过web.config配置文件解决传输内容过大问题
- docker build
- 解决ligerUI在设置的checkbox后因某些列内容过大导致的样式错位问题
- 的发送到发送到
- 不通过创建线程来实现函数间的同步
- poj 2887 Big String
- 对象拷贝类
- delphi中Message消息的使用方法
- Android 图片缓存之内存缓存技术LruCache,软引用
- build docker镜像时发送到deamo的内容过大问题
- jsp乱码问题的解决(引的)
- Linux 命令学习之df and du
- HDU 1556 Color the ball
- Thinkpad x250安装Windows10后指纹识别的问题
- csdn多少分可以看到排名!
- 字符串,数组,字典写入本地文件和从本地文件读取
- 怎样实现iMindMap中分支格式的更换
- Spark源码分析之三:Stage划分