Docker Dockerfile COPY vs ADD
If
<src>
is a URL and<dest>
does not end with a trailing slash, then a file is downloaded from the URL and copied to<dest>
.If
<src>
is a URL and<dest>
does end with a trailing slash, then the filename is inferred from the URL and the file is downloaded to<dest>/<filename>
. For instance,ADD http://example.com/foobar /
would create the file/foobar
. The URL must have a nontrivial path so that an appropriate filename can be discovered in this case (http://example.com
will not work).
If
<src>
is a local tar archive in a recognized compression format (identity, gzip, bzip2 or xz) then it is unpacked as a directory. Resources from remote URLs are not decompressed. When a directory is copied or unpacked, it has the same behavior astar -x
: the result is the union of:- Whatever existed at the destination path and
- The contents of the source tree, with conflicts resolved in favor of "2." on a file-by-file basis.
最新文章
- python浅谈正则的常用方法
- Android 跑马灯
- C#的变迁史 - C# 4.0 之多线程篇
- c# select标签绑定枚举,并以Description做Text显示
- 使用 python 操作 redis
- [vijos P1034] 家族
- 完美解决方案,可排除DATASET不支持System.Nullable错误
- xaml中绑定单例属性
- WPF学习笔记3&mdash;&mdash;Layout之1
- Extjs 3.0 htmleditor实现插入图片功能
- linux_创建用户_copy远程文件_解压缩_执行
- 使用Angular CLI进行单元测试和E2E测试
- 一次使用innobackupex重新搭建主从复制报错解决方法及注意事项
- 使用kettle来根据时间戳或者批次号来批量导入数据,达到增量的效果。
- 将HTML页面自动保存为PDF文件并上传的两种方式(一)-前端(react)方式
- Openresty 学习笔记(二)Nginx Lua 正则表达式相关API
- ArcGis辅助编号(半自动)功能的插件式实现
- Git在eclipse中的使用,克隆导入eclipse项目
- crm 中使用的Django方法
- [CodeForces - 197F] F - Opening Portals