Commit Graph

295 Commits

Author SHA1 Message Date
5850f3450f Builder counts from 1
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 17d6c6c7e514d6cea0820c6e81924413e9416cad
Component: engine
2015-08-26 10:05:04 -07:00
b498641d47 Merge pull request #14665 from coolljt0725/fix_build_with_resource_limit
Fix build with resource limit which system not support.
Upstream-commit: 6f8c4480e4f99b08c84d25f1611d6b12ee646066
Component: engine
2015-08-25 16:42:13 +02:00
49eee7cf68 Add some builder getEnv tests
In particular I want to make sure that calling getEnv() when the same
var name appears more than once in the env list that we only pick up
the first one.  PR #15182 counts on this

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: eeeae2c235f0f075284008cced669de177dd8747
Component: engine
2015-08-22 13:12:43 -07:00
a9c24d4837 integration-cli: add a integration test to avoid parsing null string in ADD, COPY and VOLUME to nil slice
Signed-off-by: Soshi Katsuta <katsuta_soshi@cyberagent.co.jp>
Upstream-commit: d45fcc6c80bd67ee6a06821fd64cad029d3a756f
Component: engine
2015-08-19 11:11:46 +09:00
8728d5d064 builder: avoid decoding "null" string in ADD, COPY and VOLUME step to nil slice
Signed-off-by: Soshi Katsuta <katsuta_soshi@cyberagent.co.jp>
Upstream-commit: 2d6952e8a52168f7204fc6834e6f5d28a5b21a37
Component: engine
2015-08-18 21:15:57 +09:00
6442b64e6e Fix build with resource limit which system is not support.
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: 770daa15f359ddc7329a2a031332c251e5a53a29
Component: engine
2015-08-18 11:54:00 +08:00
d9d9dff9a7 Merge pull request #15579 from Microsoft/10662-graph
Windows: Graph remove custom interface, add central store
Upstream-commit: 2e7b088164960b7981a058f34336c05dc52f2c53
Component: engine
2015-08-17 10:45:48 -07:00
73f39654a9 Windows: Graph remove custom interface and add central store
Signed-off-by: Stefan J. Wernli <swernli@microsoft.com>

Windows: add support for images stored in alternate location.

Signed-off-by: Stefan J. Wernli <swernli@microsoft.com>
Upstream-commit: dfbb5520e3b35030f3eef38d5a2d86ad20ea0a2f
Component: engine
2015-08-14 23:45:53 -07:00
49c0f6d3fb Windows: Block 'FROM scratch'
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 6df6e2e405a08bac2a81639349bc9a20c6014619
Component: engine
2015-08-14 18:17:19 -07:00
880ecdb34d Windows: Stop commit on running container
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 4b933dd2eaae17e4931b7414e3cead370124ec5a
Component: engine
2015-08-13 22:17:03 -07:00
0baccb159d Windows: Error on unsupported builder command
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 394ccfac0782d9877b430b5c7ef75374edcb94e8
Component: engine
2015-08-12 10:02:23 -07:00
2c6e673ce7 typofix - https://github.com/vlajos/misspell_fixer
Signed-off-by: Veres Lajos <vlajos@gmail.com>
Upstream-commit: 514623272398574c8fd7ef3fe42c5b2ae161349a
Component: engine
2015-08-07 23:25:49 +01:00
87c1161542 Just add some code doc around the use of AddXXX func to avoid any confusion
Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: 592908c0f5dbad90205764002d7b0079ad18b7a4
Component: engine
2015-08-07 08:07:27 -07:00
761b152e62 Fix uses of "int" where "int64" should be used instead
Some structures use int for sizes and UNIX timestamps. On some
platforms, int is 32 bits, so this can lead to the year 2038 issues and
overflows when dealing with large containers or layers.

Consistently use int64 to store sizes and UNIX timestamps in
api/types/types.go. Update related to code accordingly (i.e.
strconv.FormatInt instead of strconv.Itoa).

Use int64 in progressreader package to avoid integer overflow when
dealing with large quantities. Update related code accordingly.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 1f61084d83aea37b212468aaa975020094b7f7c9
Component: engine
2015-07-31 16:31:40 -07:00
59df5a01ec make docker compile on freebsd
Signed-off-by: Alexey Guskov <lexag@mail.ru>
Upstream-commit: 26c03d561ab126287bb3034cc23477d18869a888
Component: engine
2015-07-29 21:25:56 +03:00
3d5c90498b Merge pull request #14759 from vdemeester/pkg-golint
golint on some pkg/* packages
Upstream-commit: 25c42cc0d0a83325817e5fdb8fa654c9e5ab54d5
Component: engine
2015-07-27 15:19:46 -07:00
2db54e3ac2 Lint on pkg/* packages
- pkg/useragent
- pkg/units
- pkg/ulimit
- pkg/truncindex
- pkg/timeoutconn
- pkg/term
- pkg/tarsum
- pkg/tailfile
- pkg/systemd
- pkg/stringutils
- pkg/stringid
- pkg/streamformatter
- pkg/sockets
- pkg/signal
- pkg/proxy
- pkg/progressreader
- pkg/pools
- pkg/plugins
- pkg/pidfile
- pkg/parsers
- pkg/parsers/filters
- pkg/parsers/kernel
- pkg/parsers/operatingsystem

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 18c7c67308bd4a24a41028e63c2603bb74eac85e
Component: engine
2015-07-27 21:26:21 +02:00
b61648e148 Lint fixes on runconfig
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 5170a2c096ff64d4bfbe0fab296ec6777c412bc3
Component: engine
2015-07-27 21:23:15 +02:00
Lei
b278b668e9 Add ulimit to docker build.
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: 877dbbbde8aaf6583a81d9946e4c83db8e356b1a
Component: engine
2015-07-23 10:26:06 +08:00
43c8d7a97f Fix golint warnings for builder
Addresses: #14756

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: 8c4a282a5719455cb5c63b917deb2a2042eed685
Component: engine
2015-07-22 13:29:03 +08:00
b70343dc2b Fixing Image struct to no longer use Graph.
Signed-off-by:  John Howard <jhoward@microsoft.com>
Upstream-commit: 9001ea26e7821239207586ad23c78c67d6926bfc
Component: engine
2015-07-20 13:59:53 -07:00
371476f565 fix 8926: rmi dangling is unsafe when pulling
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
Signed-off-by: Tibor Vass <tibor@docker.com>
Upstream-commit: 1b67c38f6f4a709e1d159445b56f0beee8cfad3a
Component: engine
2015-07-17 11:39:57 -04:00
4f73cb3ecd Cleanup build tmp dir stuff
If there's an error while unpacking the build context then we weren't erasing
the tmp dir created to persist the context.

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: 13c08b898b1ad26dda2900c90314afa0bd2d3a1f
Component: engine
2015-07-15 06:23:19 -07:00
737b8d4b0e Windows: Fix builder
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 2ceb1146078f900a686019398a94d113943beeb9
Component: engine
2015-07-12 09:06:18 -07:00
e92413dd0d Merge pull request #14371 from Microsoft/10662-graphdriver
Windows: Graph driver implementation
Upstream-commit: 4aeb84612f530d01e0b4f5b3fff40d2a6978f6f4
Component: engine
2015-07-10 15:35:00 -07:00
1296feade8 Windows: Graph driver implementation
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 52f4d09ffb376ffaa6677cb1e0413c6a97f53f24
Component: engine
2015-07-10 14:33:11 -07:00
5b5bcdcb21 Align 'docker commit' docs with the code
It was missing some variants and 'maintainer' isn't actually supported.
Also sorted the list of allowed cmds in the code just to make it easier
to diff with the docs.

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: 0bf0e5a6efb6d4718f18db11084295aaba2062e3
Component: engine
2015-07-09 13:17:47 -07:00
576b04d570 Merge pull request #13744 from turtlebender/feature/whitelist-label-for-commit
Support LABEL as change for `docker commit`
Upstream-commit: 53b897ce9c1f815a047682edb4ca54baea395a64
Component: engine
2015-07-01 10:57:33 -07:00
9161e24479 Move /nat to /pkg/nat
By convention /pkg is safe to use from outside the docker tree, for example
if you're building a docker orchestrator.

/nat currently doesn't have any dependencies outside of /pkg, so it seems
reasonable to move it there.

This rename was performed with:

```
gomvpkg -vcs_mv_cmd="git mv {{.Src}} {{.Dst}}" \
	-from github.com/docker/docker/nat \
        -to   github.com/docker/docker/pkg/nat

```

Signed-off-by: Peter Waller <p@pwaller.net>
Upstream-commit: 9c2374d19623581028f070bc93fa4c60a660dce4
Component: engine
2015-06-30 17:43:17 +01:00
a8c9aef74e Merge pull request #14061 from runcom/clean-builder-daemon-config
Add struct to configure Builder commit
Upstream-commit: d543a01e17ace181261dd7809bbeec0c6580b867
Component: engine
2015-06-29 11:04:05 -07:00
3c4d6e026e Merge pull request #14139 from jlhawn/fix_build_with_auth
[api, builder] Fix build auth config
Upstream-commit: dd408891baff5cd820f917a001364add35f5f878
Component: engine
2015-06-25 17:39:36 -07:00
aa8bc7e1e7 [api, builder] Fix build auth config
With the 1.7 release, we introduced a change to how we store registry
credentials, but the build API endpoint did not expect a change in the format
of that file. This patch fixes this problem so that you can again pull private
images during `docker build`.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
Upstream-commit: 02c7bbefb8841e5e86a4b9d467defa668e3ea613
Component: engine
2015-06-23 12:58:17 -07:00
9a58f60656 Merge pull request #13833 from Microsoft/10662-dockerbuild
Windows: Start docker build working
Upstream-commit: d5721f03854f33300f84186554321c3371a28319
Component: engine
2015-06-23 11:46:56 -07:00
4992f31e42 Merge pull request #14071 from mavenugo/mhnet
Vendoring libnetwork 83743db8ceb2bdbfa0960d9a54ed2f98df4ea846
Upstream-commit: f39b9a0b0f77c528a6fb8bf14be5cdea11ce338d
Component: engine
2015-06-22 08:35:18 -07:00
aa388c828f Removed the default "bridge" in builder
Now that the default network mode is "default" and this mode is chosen
even if the mode is empty string, it is not correct to have builder
still pointing to "bridge" as default (though this is daemon default).

Signed-off-by: Madhu Venugopal <madhu@docker.com>
Upstream-commit: 53b0f686f7ee338819e568413fd9daf9c3811d68
Component: engine
2015-06-22 04:15:56 -07:00
681944f56f Add struct to configure Builder commit instead of using one defined in daemon
Signed-off-by: Antonio Murdaca <runcom@linux.com>
Upstream-commit: 7046651b87c0c028d010881abbb05a8f0c28ddfa
Component: engine
2015-06-20 12:53:47 +02:00
265055473c Support downloading remote tarball contexts in builder jobs.
Signed-off-by: Moysés Borges <moysesb@gmail.com>
Upstream-commit: d48bface59ef28aedc692c1f7c51a7ddde94a7fe
Component: engine
2015-06-19 16:35:00 -03:00
84f0d29cf2 Windows: Docker build starting to work
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 3c177dc8777e76b4913294d17da4eac30edbd8db
Component: engine
2015-06-17 10:41:28 -07:00
8124231ae2 just adding label to whitelist for commit command (Fixes #13738)
Signed-off-by: Tom Howe <turtlebender@gmail.com>
Upstream-commit: 6e2662b3bad319679e17fe25d410f246820ab0e9
Component: engine
2015-06-16 13:59:16 -05:00
57eb64c9c0 Carry of PR #13520
Removinig files

Signed-off-by: Mary Anthony <mary@docker.com>
Upstream-commit: cd44018856be421497a35d96f88dd0eec42fae43
Component: engine
2015-06-13 09:27:30 -07:00
e778cd68a0 [builder] Make build cache ignore mtime
Build cache uses pgk/tarsum to get a digest of content which is
ADD'd or COPY'd during a build. The builder has always used v0 of
the tarsum algorithm which includes mtimes however since the whole
file is hashed anyway, the mtime doesn't really provide any extra
information about whether the file has changed and many version
control tools like Git strip mtime from files when they are cloned.

This patch updates the build subsystem to use v1 of Tarsum which
explicitly ignores mtime when calculating a digest. Now ADD and
COPY will result in a cache hit if only the mtime and not the file
contents have changed.

NOTE: Tarsum is NOT a meant to be a cryptographically secure hash
function. It is a best-effort approach to determining if two sets of
filesystem content are different.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
Upstream-commit: 0e10507a1c5985e6fda0ff48e9313ba7a4de761b
Component: engine
2015-06-08 13:54:47 -07:00
6aab6b5654 Avoid nil pointer dereference while creating a container with an empty Config
Signed-off-by: Antonio Murdaca <runcom@linux.com>
Upstream-commit: 4ce817796e639391f6bc3e338f5a88985daacaca
Component: engine
2015-06-06 20:07:32 +02:00
6226136075 Remove PortSpecs from Config
Signed-off-by: Antonio Murdaca <me@runcom.ninja>
Upstream-commit: 15134a3320fbacee36e86a0342e7ffb49285f297
Component: engine
2015-05-29 22:38:09 +02:00
570b91cfd7 Merge pull request #13055 from Microsoft/10662-internalsfixperms
Windows: Fixup builder/internals.go
Upstream-commit: 33c7c01a62390d55c4433ad45dd4632cf7112f81
Component: engine
2015-05-28 12:31:45 -04:00
2b42c2c199 Cleanup container rm funcs
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: f8628ba89104385071e811d0b21293d7cd2e8e01
Component: engine
2015-05-26 15:38:52 -04:00
89782c55eb Volumes refactor and external plugin implementation.
Signed by all authors:

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Signed-off-by: Arnaud Porterie <arnaud.porterie@docker.com>
Signed-off-by: David Calavera <david.calavera@gmail.com>
Signed-off-by: Jeff Lindsay <progrium@gmail.com>
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
Signed-off-by: Luke Marsden <luke@clusterhq.com>
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 81fa9feb0cdc0773eff99d7393c16271e84aac08
Component: engine
2015-05-21 20:34:17 -07:00
34fbb3e5d5 Windows: Fixup builder\internals.go
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 010e3e046b3d31ab69f37dfb504551fe5042d84a
Component: engine
2015-05-20 08:55:13 -07:00
b3f4af8971 builder/internals: set up network as bridge
Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
Upstream-commit: d6a545a989109d3a76e8dfb4cfc0e4f9c88cd3c4
Component: engine
2015-05-15 22:58:21 +03:00
71c213ec0b Merge pull request #13131 from Microsoft/10662-loadonwindows
Windows: Build load.go
Upstream-commit: 3985f1781228d6060228d83e559f14e6d7cc9d7c
Component: engine
2015-05-12 18:04:33 -07:00
aeecef0f70 Refactor pkg/stremformatter with custom constructors instead of passing a boolean
Signed-off-by: Antonio Murdaca <me@runcom.ninja>
Upstream-commit: 6b700bdacae0b416d8239a0a24729fe327d425d1
Component: engine
2015-05-13 00:09:41 +02:00