Commit Graph

587 Commits

Author SHA1 Message Date
d6d79998e2 Allow ARG to come before FROM to support variables in FROM.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: f0a9c2e3f4ea101c8a56a31ae6cb11559bc78683
Component: engine
2017-04-07 17:57:47 -04:00
e25f6c5a1b Added start period option to health check.
Signed-off-by: Elias Faxö <elias.faxo@gmail.com>
Upstream-commit: e401f63735d8ebcff387c571d1f61ce52bdea86e
Component: engine
2017-04-06 12:35:34 +02:00
b40d1c6a48 Merge pull request #32063 from tonistiigi/named-contexts
Add support for named build stages
Upstream-commit: 2e96c1739be45f2ff8342cb3e222db3eb1616839
Component: engine
2017-04-04 12:53:59 -07:00
86cf613824 Merge pull request #31750 from dnephin/some-builder-cleanup
Fix `docker build --label` when the label includes single quotes and a space
Upstream-commit: 6abbc933ae02b69afad72e229f7b9d5ef8a6f431
Component: engine
2017-04-04 09:37:00 -07:00
71418f1299 Add support for FROM using named block
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 672ea30a94933eec228d71217b033da5d6572b8d
Component: engine
2017-04-04 09:34:28 -07:00
da4a3b24f4 Implicit copy-from with reference
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 73b4b8ed7f86b8df70d7028c5ac7c2ba61ee0a8c
Component: engine
2017-04-04 09:34:28 -07:00
d51100a9ef Add named context support
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 87512bbc8490aca261133a7f3a3ea6518d703c34
Component: engine
2017-04-04 09:34:28 -07:00
b4a1c08afc builder: Fix setting command with custom shell
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: a1fa59ea123555a910c1de1f7b88b75000f2bec4
Component: engine
2017-03-30 13:29:21 -07:00
ac093860f7 Display created tags on successful build
Signed-off-by: Alexandre Garnier <alexandre.garnier@zenika.com>
Signed-off-by: Alexandre Garnier <zigarn@gmail.com>
Upstream-commit: d0052198300dfe9fd220f780184d1ec82c50006c
Component: engine
2017-03-25 11:46:20 +01:00
20ac55606f Fix --label being env var expanded.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 434d77bc0edf21b970e0414ee54112768a490aaa
Component: engine
2017-03-24 12:29:14 -04:00
3bea1ce0e2 Fix --label on docker build when a single quote is used in the value
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 726fb269cf004814bd7065ca2f29f6955746a9d9
Component: engine
2017-03-24 12:29:14 -04:00
fa11164129 Refactor some builder code
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: d7807c73169469c50e551704cc1957f798868f71
Component: engine
2017-03-24 12:29:14 -04:00
c90ad1369f Merge pull request #31257 from tonistiigi/nested-build
build: add multi-stage build support
Upstream-commit: 2fa8fe400d926b3ceb0c84640a8f4e0f36e51463
Component: engine
2017-03-23 19:14:13 -07:00
dc0d47d701 Fix relative path on windows for uuid paths
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 684633f734f86b6a66873b42c9356eb543e12917
Component: engine
2017-03-23 15:12:19 -07:00
e59b5a1439 Add support for COPY from previous rootfs
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: f95f58283b2a69f4fd06d01de2281641e09b06bb
Component: engine
2017-03-23 15:12:15 -07:00
cc2d5e2aaf Ignore built-in allowed build-args in image history
Removes the build-args from the image history if they are in the
BuiltinAllowedBuildArgs map unless they are explicitly defined in an ARG
instruction.

Signed-off-by: Dave Tucker <dt@docker.com>
Upstream-commit: 89a2a885c82bade2774f4b669b4e09ede8f840c3
Component: engine
2017-03-21 16:36:48 +00:00
00541f8de2 Fix cache for dockerfiles with multiple FROM
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: acad599210b5c00a4f3a8eae05de21d0d9ef8a88
Component: engine
2017-03-20 11:24:50 -07:00
fb83132fe7 Fix ARG scoping for Dockerfiles with multiple FROM
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 09f308ce211cd00f24d4e0f8cc797816b4fff1b6
Component: engine
2017-03-20 11:24:44 -07:00
a835f1babb fix misspell in utils.go
Signed-off-by: Helen Xie <chenjg@harmonycloud.cn>
Upstream-commit: 2b79dbc89bf15c276145a0fa3d3728308349f86e
Component: engine
2017-03-20 19:52:00 +08:00
63bea006b9 extract a function
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 9ea5e02e92d2d39e771d10eb0acf341ba9b58ceb
Component: engine
2017-03-08 11:46:09 -05:00
a09edbbf93 Merge pull request #31177 from allencloud/donot-allow-subsecond-in-dockerfile-healthcheck
do not allow sub second in healthcheck options in Dockerfile
Upstream-commit: fb1890fb9530b3f69b0d9f937fd0b6d8b1972311
Component: engine
2017-03-08 15:18:09 +01:00
12aa0347d6 Merge pull request #30383 from TDAbboud/30096-add-host-docker-build
Add --add-host for docker build
Upstream-commit: a64ea37753fd9a94dfa3ab81f67f46df7bd641f8
Component: engine
2017-02-27 12:42:18 +01:00
458406a7f3 Merge pull request #31212 from fate-grand-order/fixed
use t.Fatal() to output the err message and fix typo
Upstream-commit: a6576b8a2bff0feeb67918403caa3df0c4c37673
Component: engine
2017-02-27 12:26:35 +09:00
f19067fd22 Refactor to remove duplicate code around BuildArgs.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 6e005fd5ccd6ba90b51212c4a2539712b6398afd
Component: engine
2017-02-24 16:22:32 -05:00
9632b0f1e8 use t.Fatal() to output the err message where the values used for formatting
text does not appear to contain a placeholder

Signed-off-by: Helen Xie <chenjg@harmonycloud.cn>
Upstream-commit: 2a8d6368d4a930203b93f75914173ab65bf3b0bc
Component: engine
2017-02-23 10:16:22 +08:00
a8278abaf1 fix wrong print format
Signed-off-by: Reficul <xuzhenglun@gmail.com>
Upstream-commit: 9b1ceecd8a44e72ad773f7016df09a4b285258b8
Component: engine
2017-02-21 10:26:06 +08:00
7dba33b4e7 Add --add-host for docker build
Signed-off-by: Tony Abboud <tdabboud@hotmail.com>
Upstream-commit: 7a962e4577628c357f96153eca07e527813fb42b
Component: engine
2017-02-20 17:32:28 -05:00
de008a1137 do not allow sub second in healthcheck options in Dockerfile
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: 63811a82b67528494f711086547580e7c40aaa93
Component: engine
2017-02-20 15:47:34 +08:00
29e3dcbbb0 why there are so many mistakes in our repo (up to /cmd)
Signed-off-by: Aaron.L.Xu <likexu@harmonycloud.cn>
Upstream-commit: f8a40477960976f12dbbb72e5b133b5b0f05f9b3
Component: engine
2017-02-17 00:32:48 +08:00
be4d0dc6ad Reset stdin config before running build actions
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: 0f293f9eb31bdf8ff7adcb31baafca3f6fde3aab
Component: engine
2017-02-15 11:49:17 -08:00
c355cec53c Merge pull request #30457 from dmcgowan/distribution-reference-update-2
reference: use distribution reference and remove fork
Upstream-commit: 254fc83cba90ed79c78f4cb0cb33aeeaff492798
Component: engine
2017-02-07 22:01:25 +01:00
6df9f2365c Merge pull request #29552 from dnephin/fix-build-with-log-driver
Ignore the daemon log config when building images
Upstream-commit: 1b4e2b7c878fb69c1c96755e21a571e6d7b8e4bb
Component: engine
2017-02-07 15:47:41 -05:00
2260389fe6 Use distribution reference
Remove forked reference package. Use normalized named values
everywhere and familiar functions to convert back to familiar
strings for UX and storage compatibility.

Enforce that the source repository in the distribution metadata
is always a normalized string, ignore invalid values which are not.
Update distribution tests to use normalized values.

Signed-off-by: Derek McGowan <derek@mcgstyle.net> (github: dmcgowan)
Upstream-commit: 3a1279393faf78632bf169619d407e584da84b66
Component: engine
2017-02-07 11:08:37 -08:00
666b6151bb Merge pull request #30542 from skabashnyuk/master
Fixes work of inspectResponse in case of ContentLength=-1
Upstream-commit: 04f0e616f2472612e62ee27dd56c542c2f52afff
Component: engine
2017-01-30 22:54:49 +01:00
1c2a160811 Ignore the daemon log config when building images.
Logs created by build containers should be handled by the daemon, not by logging drivers.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 80b642ff881d21ba6d006b8e52458335462d05b6
Component: engine
2017-01-30 10:59:19 -05:00
cee836fc39 Added test for the case if ContentLength = -1
Signed-off-by: Sergii Kabashniuk <skabashnyuk@codenvy.com>
Upstream-commit: 28d59e57ca0c718fe5d7531626be1fe3b9b6564a
Component: engine
2017-01-30 10:05:05 +02:00
4318d69af3 Fixes work of inspectResponse in case of ContentLength=-1
Signed-off-by: Sergii Kabashniuk <skabashnyuk@codenvy.com>
Upstream-commit: 22a9ec009b24f567e1feaeb32da25d6b2792c92a
Component: engine
2017-01-29 20:48:07 +02:00
3c805f2872 Remove unnecessary if in parser.Dump
Signed-off-by: Anthony Sottile <asottile@umich.edu>
Upstream-commit: 2283cd020373ebd00e5cf37a81df451349c3b506
Component: engine
2017-01-28 23:07:24 -08:00
ae5b65a856 Merge pull request #30208 from justincormack/no-sqlite
Remove sqlite dependency
Upstream-commit: 0e8c7d72771847227df295471ac73180cbb3caa9
Component: engine
2017-01-18 13:15:38 -05:00
ecfeb35159 Remove sqlite
This drops support for migrations from pre-1.10 Docker versions, which
should be done via an external tool or an intermediate upgrade.

Signed-off-by: Justin Cormack <justin.cormack@docker.com>
Upstream-commit: f8119bb7a76b5c42defb6e0a2dc67bd77ad29a5e
Component: engine
2017-01-18 12:27:21 +00:00
287ee51be3 Refactoring ineffectual assignments
This patch fixed below 4 types of code line
1. Remove unnecessary variable assignment
2. Use variables declaration instead of explicit initial zero value
3. Change variable name to underbar when variable not used
4. Add erro check and return for ignored error

Signed-off-by: Daehyeok Mun <daehyeok@gmail.com>
Upstream-commit: 6306019d0bad9c4e60ee437e93f2450dfb0b68c0
Component: engine
2017-01-13 00:27:01 -07:00
2cf38188cb Merge pull request #30039 from ripcurld0/specify_line_no_dockerfile_err
Specify in which line the Dockerfile parser failed
Upstream-commit: 597843e79040a4f00bfe2abd83343d43edd195f5
Component: engine
2017-01-12 19:48:45 -05:00
a1c6880e0b Specify in which line the Dockerfile parser failed
Signed-off-by: Boaz Shuster <ripcurld.github@gmail.com>
Upstream-commit: 8f282cdea5186896923da02f420e929c8ded61cb
Component: engine
2017-01-12 17:45:45 +02:00
cc35939485 Revert "Require continuation char to be last char in a line"
This reverts commit 105bc63295a7126798d3722a0e205c5ead4e2b1c,
which (although correct), resulted in a backward incompatible
change.

We can re-implement this in future, after this changes goes
through a deprecation cycle

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: c67550414b762ab32ea3e9645ebcafb79cb9059d
Component: engine
2017-01-10 00:41:03 +01:00
236f68013a Fix workdir cache invalidation
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: e16086005425b626bccc0fedcf5ae195f913c636
Component: engine
2017-01-06 12:10:59 -08:00
6b3d2b6135 Merge pull request #28631 from likel/master
Don't do format if it's unnecessary
Upstream-commit: d6be0e98027611cfb14a3246ca797bee0936e649
Component: engine
2016-12-30 01:13:12 +01:00
7b188d600d Merge pull request #29624 from yongtang/29619-build-label-order
Sort the labels passed from `build --labels`
Upstream-commit: aacc2c88803b4b908a4e565a1dd5f7fafa5e54f0
Component: engine
2016-12-29 15:09:53 -08:00
b4cbe892e8 Merge pull request #29679 from yongtang/29667-docker-build-workdir-cmd
Fix image's `CMD` after `WORKDIR` in Dockerfile
Upstream-commit: a2b12b5e82d50dad6c4a109501260f2307cf1d75
Component: engine
2016-12-28 20:26:59 -05:00
22afb90b38 Merge pull request #29752 from allencloud/fix-nits-in-comments
fix nits in comments
Upstream-commit: 9fab262690a1e9c465687b3dc22f84b053c5624f
Component: engine
2016-12-28 08:33:48 -05:00
0cddfcad2f fix nits in comments
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: 6fb05778ba241b344dd9014ff1091e3f70a8b40c
Component: engine
2016-12-27 23:30:50 +08:00