Commit Graph

203 Commits

Author SHA1 Message Date
b0ff606238 docs: added support for CLI yaml file generation
Signed-off-by: French Ben <frenchben@docker.com>
Signed-off-by: Tibor Vass <tibor@docker.com>
Upstream-commit: 5443f0152f77eb983e6475474b02c2e11d975f1c
Component: engine
2017-03-14 16:04:08 -07:00
324d1b77a6 Merge pull request #29775 from AkihiroSuda/integration-cli-on-swarm
[EXPERIMENTAL] Integration Test on Swarm (completes in about 5 minutes, with 10 Swarm nodes)
Upstream-commit: 01ed606439976e8a159c2a8406228ac52941ae47
Component: engine
2017-03-01 21:16:05 +01:00
08d9b7c8f6 pass DOCKER_CROSSPLATFORMS to the container in the Makefile
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
Upstream-commit: 8aa1158164d218dc8d63ec4dcedf7cd7b8b3f28c
Component: engine
2017-02-28 10:14:19 -08:00
e642076136 [EXPERIMENTAL] Integration Test on Swarm
This commit adds contrib/integration-cli-on-swarm/integration-cli-on-swarm.sh,
which enables IT to be running in parallel, using Swarm-mode and Funker.

Please refer to contrib/integration-cli-on-swarm/README.md

The test takes almost 5 to 6 minutes, with 10 n1-standard-4 GCE instances.

  $ ./contrib/integration-cli-on-swarm/integration-cli-on-swarm.sh --push-worker-image example.gcr.io/foo/bar --replicas 30 --shuffle
  2016/12/29 08:32:15 Loaded 1618 tests (30 chunks)
  2016/12/29 08:32:15 Executing 30 chunks in parallel, against "integration-cli-worker"
  2016/12/29 08:32:15 Executing chunk 0 (contains 54 test filters)
  ..
  2016/12/29 08:34:34 Finished chunk 28 [1/30] with 54 test filters in 2m19.098068003s, code=0.
  2016/12/29 08:34:38 Finished chunk 12 [2/30] with 54 test filters in 2m23.088569511s, code=0.
  2016/12/29 08:34:48 Finished chunk 10 [3/30] with 54 test filters in 2m33.880679079s, code=0.
  2016/12/29 08:34:54 Finished chunk 20 [4/30] with 54 test filters in 2m39.973747028s, code=0.
  2016/12/29 08:35:11 Finished chunk 18 [5/30] with 54 test filters in 2m56.28384361s, code=0.
  2016/12/29 08:35:11 Finished chunk 29 [6/30] with 52 test filters in 2m56.54047088s, code=0.
  2016/12/29 08:35:15 Finished chunk 1 [7/30] with 54 test filters in 3m0.285044426s, code=0.
  2016/12/29 08:35:22 Finished chunk 6 [8/30] with 54 test filters in 3m7.211775338s, code=0.
  2016/12/29 08:35:24 Finished chunk 25 [9/30] with 54 test filters in 3m9.938413009s, code=0.
  2016/12/29 08:35:30 Finished chunk 27 [10/30] with 54 test filters in 3m15.219834368s, code=0.
  2016/12/29 08:35:36 Finished chunk 9 [11/30] with 54 test filters in 3m21.615434162s, code=0.
  2016/12/29 08:35:41 Finished chunk 13 [12/30] with 54 test filters in 3m26.576907401s, code=0.
  2016/12/29 08:35:45 Finished chunk 17 [13/30] with 54 test filters in 3m30.290752537s, code=0.
  2016/12/29 08:35:53 Finished chunk 2 [14/30] with 54 test filters in 3m38.148423321s, code=0.
  2016/12/29 08:35:55 Finished chunk 24 [15/30] with 54 test filters in 3m40.09669137s, code=0.
  2016/12/29 08:35:57 Finished chunk 8 [16/30] with 54 test filters in 3m42.299945108s, code=0.
  2016/12/29 08:35:57 Finished chunk 22 [17/30] with 54 test filters in 3m42.946558809s, code=0.
  2016/12/29 08:35:59 Finished chunk 23 [18/30] with 54 test filters in 3m44.232557165s, code=0.
  2016/12/29 08:36:02 Finished chunk 3 [19/30] with 54 test filters in 3m47.112051358s, code=0.
  2016/12/29 08:36:11 Finished chunk 15 [20/30] with 54 test filters in 3m56.340656645s, code=0.
  2016/12/29 08:36:11 Finished chunk 11 [21/30] with 54 test filters in 3m56.882401231s, code=0.
  2016/12/29 08:36:22 Finished chunk 19 [22/30] with 54 test filters in 4m7.551093516s, code=0.
  2016/12/29 08:36:23 Finished chunk 21 [23/30] with 54 test filters in 4m8.221093446s, code=0.
  2016/12/29 08:36:25 Finished chunk 16 [24/30] with 54 test filters in 4m10.450451705s, code=0.
  2016/12/29 08:36:27 Finished chunk 5 [25/30] with 54 test filters in 4m12.162272692s, code=0.
  2016/12/29 08:36:28 Finished chunk 14 [26/30] with 54 test filters in 4m13.977801031s, code=0.
  2016/12/29 08:36:29 Finished chunk 0 [27/30] with 54 test filters in 4m14.34086812s, code=0.
  2016/12/29 08:36:49 Finished chunk 26 [28/30] with 54 test filters in 4m34.437085539s, code=0.
  2016/12/29 08:37:14 Finished chunk 7 [29/30] with 54 test filters in 4m59.22902721s, code=0.
  2016/12/29 08:37:20 Finished chunk 4 [30/30] with 54 test filters in 5m5.103469214s, code=0.
  2016/12/29 08:37:20 Executed 30 chunks in 5m5.104379119s. PASS: 30, FAIL: 0.

Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
Upstream-commit: 28797019b3f0eb288c4b201237cb992ec148dd4c
Component: engine
2017-02-28 02:10:09 +00:00
ba32ae9bba Bind mount .git 👼
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 617be0ef2bbbce6f0e908734f8a5f2b6a7b93877
Component: engine
2017-02-03 21:00:32 +01:00
7e467dc7f7 Do not required .git in the build context
- export DOCKER_GITCOMMIT in the Makefile
- prioritize DOCKER_GITCOMMIT against the `git` command in
  `./hack/make.sh`
- Also add `integration-cli/bundles` to gitignore (it's generated when
  using integration-cli shell)

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: fae6ca2bb42d9c4146df413bcce701431298161c
Component: engine
2017-01-24 14:42:57 +01:00
d600e911d9 Add the possibility to set the dev container name
By using `make CONTAINER_NAME=docker-dev shell` you're able to name
the docker-dev container to what you want. The idea behind it is by
knowing the name of your dev container you can automate easily some
thing using `docker exec` later.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 4bda9bd6e9f4a2b59b35ab381e506df708875703
Component: engine
2016-12-16 10:24:16 +01:00
e56158d95b Add make command for previewing API docs
Much easier than the previous method of copying over to the docs
repository and generating the docs.

And, as @cpuguy83 pointed out, that actually didn't work
because the PR that adds Swagger docs isn't merged yet. Oopsy.

Signed-off-by: Ben Firshman <ben@firshman.co.uk>
Upstream-commit: 27ca33e965b78df4d0e7be5597c2f48d9286775f
Component: engine
2016-12-14 12:27:32 +00:00
655301f8a7 Use named volumes for docker pkg cache
Changes the default when incremental build is enabled to use named
volumes instead of bindmounts.
The reason for this is, on Mac/Windows the bind mounts will go over the
shared fs, which is incredibly slow and itself uses lots of CPU.

Makes an incremental build on OSX go from ~40s to 10s.

To get the old behavior, can set `PKGCACHE_DIR=.go-pkg-cache`

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: c9623d1b7619dfffe01fa47b4338637945c1a53f
Component: engine
2016-12-05 20:42:08 -05:00
9a6dc26e71 Merge pull request #29069 from vdemeester/29031-manpages-buildarg
Use DOCKER_BUILD_ARGS on manpages make target
Upstream-commit: fddb5a7f2ab29be441bc797f7e79fffc5cc531d3
Component: engine
2016-12-02 12:30:36 -05:00
966bc9c966 Use DOCKER_BUILD_ARGS on manpages make target
This make it more consistent with the other image builds and allow to
build manpages behind a proxy for example.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 58505ffdeeb453035091ebe59d3de18193b18d1b
Component: engine
2016-12-02 14:20:30 +01:00
61372ea9bb pin go-swagger 0.7.4
This pins the version of go-swagger used, because
the results generated by different versions
can differ quite a bit (tested between 0.7.2 - 0.7.4),
and can cause CI / validation to fail.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: ba20c3e65e33ac6b29294a0eb43d713aa319ef7a
Component: engine
2016-12-02 01:36:46 +01:00
fadee20b95 Build docker incrementally by default
This speeds up docker build time drastically. It still possible to
disable this by setting `DOCKER_INCREMENTAL_BUILD` to `0` (and this is
what should be done on the CI).

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 2c342cff79d6e781e06258cefcd2b2b1a23396ec
Component: engine
2016-11-15 16:23:48 +01:00
61646d77af project: use vndr for vendoring
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
Upstream-commit: f2614f2107c838d014d31b806e3b8a9f1395cb2b
Component: engine
2016-11-03 15:31:46 -07:00
dd0403a2eb Move validation out of hack/make
Allow each script to run directly without the hack/make.sh wrapper. These
scripts do not produce artifacts and do not benefit from the "bundles"
framework.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 22033e10034884734621f185b60ddaa119014480
Component: engine
2016-11-03 14:24:22 -06:00
b95b382b85 Fix swagger-gen.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 252963bd3fe14e5e89b9e19f29e2936253d35fcf
Component: engine
2016-11-02 10:48:34 -04:00
3f110de0ac Add whitespace and create a script to run generation
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 02e1ffd76c517f8b9832fada9ba31445f90f2d7f
Component: engine
2016-10-20 13:24:23 -07:00
b8b81c7fa0 Generate api/types:Image from the swagger spec
and rename it to a more appropriate name ImageSummary.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: b06c3527831a585ac7e44d0b3ea060cc2092e6ef
Component: engine
2016-10-20 13:24:23 -07:00
247fb589b6 Generate api/types:Port from swagger spec.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: f06d8d6db991199ea5e5fcf527ff96f0d00c3a45
Component: engine
2016-10-20 13:24:23 -07:00
07a14ff9a8 Add swagger.yaml
Generate Volume type from the swagger.yaml
Add makefile target for generating the models

Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 0243936d92ea57f48c6a32beac797ee3b388ba28
Component: engine
2016-10-20 13:24:23 -07:00
24ba04043a Add a link to the new build instructions
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: 3aeaa9f8fdb835e44edae04d7b43b85e66fcb4c3
Component: engine
2016-10-14 14:05:48 -07:00
d1a1df20f1 Fix issue with bundles dir volume
The bundles dir used to be automatically made a volume if BINDDIR was
not set.

The `PKGCACHE_*` stuff was added recently which gets added to
`DOCKER_MOUNT`. This breaks the case where someone wants to use the
package cache (DOCKER_INCREMENTAL_BINARY is enabled) but has not
specified a bind dir but needs the bundles dir made a volume.

Moves the package cache handling to after the bundles dir is made a
volume.

Before this patch, if you have `DOCKER_GRAPHDRIVER` set to anything
other than vfs, the tests in the daemon suite (and swarm suite, and
registry suite) will fail to run since they cannot startup a daemon
(except for speicifc cases where <driver> over <driver> is possible,
like devmapper).

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: a95ad53ca404cefd21a3efe2dc8c35c083df5a2b
Component: engine
2016-09-22 16:49:28 -04:00
e2b900a8b1 Merge pull request #26375 from cpuguy83/fix_apt_mirror_propagation
Propagate BUILD_APT_MIRROR and consume in buil-deb
Upstream-commit: da7a7f9b769f6c1ccc88526390a3ff6528e31eb9
Component: engine
2016-09-09 00:02:42 +01:00
2a13e97eec Propagate BUILD_APT_MIRROR and consume in buil-deb
Passses down BUILD_APT_MIRROR to the docker env.
Ensures BUILD_APT_MIRROR is used when building debs, but only when the
consuming `Dockerfile` actually uses it, otherwise it will cause the
build to fail (e.g. on Ubuntu builds we aren't using APT_MIRROR).

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: f672a963c9f1225daec9d2d12577f95936dee51e
Component: engine
2016-09-07 10:57:00 -04:00
b03700a5d5 Verify integration tests before building bundles
Adds a new bundle `verify-integration-tests` which pre-compiles a test
binary for the integration tests.

This makes sure that the integration tests will actually compile before
doing other tasks which take much longer, such as building dockerd and
loading test fixtures.
When it comes time to actually run the tests, the pre-compiled binary
will be used so it doesn't have to compile the tests a 2nd time.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 4d0275c8192ca39d88f7dbe1e59ec03b544b6696
Component: engine
2016-09-06 20:27:28 -04:00
691c290c4d Merge pull request #26123 from cpuguy83/revert_makefile_build_args
Fix passing custom APT_MIRROR on building Docker
Upstream-commit: 5c2064f890fb1fa5f3642ae135e5145d4bd0ae13
Component: engine
2016-08-30 17:30:48 +02:00
82132c60b7 Pass through build APT_MIRROR as separate var
DOCKER_BUILD_APT_MIRROR

This allows passthrough of other options like HTTP_PROXY from
DOCKER_BUILD_ARGS to work on all builds (for example,
ensure-syscall-test) when APT_MIRROR is set.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 39c87c79c848456aaa12a6ecfd658a9e94f94d65
Component: engine
2016-08-30 09:09:31 -04:00
b2e9b172d4 Alphabetize makefile targets
Sorts the makefile targets alphabetically

Signed-off-by: Christopher Jones <tophj@linux.vnet.ibm.com>
Upstream-commit: c2775c0b67940467889aa0c20d1be135cbe7623e
Component: engine
2016-08-29 14:06:45 -04:00
4cad859c7a Merge pull request #25978 from justincormack/no-no-gccgo
Remove gccgo support
Upstream-commit: 8d99dfbc69a18cbf1e604b845df76fdedcf2e853
Component: engine
2016-08-25 12:12:29 -07:00
904fc9b879 Merge pull request #25481 from keloyang/build-args-docker-env
Add DOCKER_BUILD_ARGS to DOCKER_ENVS in Makefile
Upstream-commit: a36016cd3a883aa7603251aeff0a259555235bb5
Component: engine
2016-08-25 18:56:08 +02:00
4d71bb6be2 Remove gccgo support
Since Go 1.7, s390x uses upstream Go, so we have no reason to
support gccgo any more.

Signed-off-by: Justin Cormack <justin.cormack@docker.com>
Upstream-commit: eda90f63446253f97d2011926555306f2417d208
Component: engine
2016-08-24 11:09:35 +01:00
46c68f2339 keep the same between rules and PHONY
Signed-off-by: yuexiao-wang <wang.yuexiao@zte.com.cn>
Upstream-commit: bf3d1d1e5a39cb66ff58cedbcc9d6e84163a35f8
Component: engine
2016-08-19 09:08:39 +08:00
b049961e1b Add DOCKER_BUILD_ARGS to DOCKER_ENVS in Makefile
Signed-off-by: Shukui Yang <yangshukui@huawei.com>
Upstream-commit: 4aa9b9c5b3da4c6d2478726824dbbfa2b1f5d1a7
Component: engine
2016-08-10 11:09:07 +08:00
c733ccf2f5 Cleanup manpage container in build process
When running a `make manpages` the image `docker-manpage-dev` will be build and started to create
the man pages. But the container will not be deleted afterwards. So I propose to start it with
`docker run --rm ...`, otherwise we'll collect some trash.
```
$ docker ps -a
CONTAINER ID        IMAGE                COMMAND                  CREATED             STATUS                      PORTS               NAMES
e3d9f721d862        docker-manpage-dev   "man/generate.sh"        19 minutes ago      Exited (0) 16 minutes ago                       berserk_jang
5738a23fb682        docker-manpage-dev   "man/generate.sh"        9 hours ago         Exited (0) 9 hours ago                          boring_bartik
15490b5e63f7        docker-manpage-dev   "man/generate.sh"        10 hours ago        Exited (0) 10 hours ago                         lonely_joliot
```

Signed-off-by: Dieter Reuter <dieter.reuter@me.com>
Upstream-commit: 12c10239bbff1def439193d4681464640446bfbb
Component: engine
2016-08-06 10:20:16 +02:00
c523846cca Fix the man/Dockerfile for arm
Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: fcde27e6db9ccdb952a1259788404fc500995f98
Component: engine
2016-08-02 12:56:05 -04:00
592a15f46b mount .go-pkg-cache for DOCKER_INCREMENTAL_BINARY
The cache was not used when we run `make binary` from the host.

Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
Upstream-commit: 389d5cde7b5474cd33d251aadc96be1f0bdbc711
Component: engine
2016-07-20 08:20:38 +00:00
9ed298d21b Add a script to generate man pages from cobra commands.
Use the generate.sh script instead of md2man directly.
Update Dockerfile for generating man pages.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 00a8a40398263429f99b1a5f0be59048e1c6f38d
Component: engine
2016-07-19 12:00:21 -04:00
bfc9affa26 Merge pull request #24280 from miaoyq/24261-fix-make-docker-py-err
Fix 'make test-docker-py' error
Upstream-commit: 13fcbe3d53d3baab4391b23db3e48b4aad877eaa
Component: engine
2016-07-16 02:07:23 +02:00
2b20a57f68 Fix 'make test-docker-py' error
Signed-off-by: Yanqiang Miao <miao.yanqiang@zte.com.cn>
Upstream-commit: c125bbd5e8dcbc0d64d2489df0dc901cb4f62ff4
Component: engine
2016-07-09 11:52:33 +08:00
e28870f6c9 Add target for make run
`make run` allows you to fire up a daemon (in a container) just using
the existing built binaries. This allows for more rapid iteration
instead of dealing with firing up a shell just to start the daemon.

By default the daemon will listen on port 2375 on the default network
interface.

If a port forward is required to access the daemon, the user can set
`make DOCKER_PORT=2375 run` to get a port forward on a random port with
the daemon listening on port 2375, or `make DOCKER_PORT=2375:2375 run`
to get a daemon running with port 2375 forwarded to the daemon running
on 2375.

Note that the daemon is automatically configured to listen on whatever
port is set for the container side of the `DOCKER_PORT` port spec.

When running on docker4mac, the user must do the following:
```
$ make BINDDIR=. DOCKER_PORT=2375 run
```

This makes sure the binaries are loaded in the container and a port is
forwarded, since it is currently impossible to route traffic from the
mac directly to a container IP.

To get a fresh binary:
```
$ make BINDDIR=. DOCKER_PORT=2375 binary run
```

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: cae890bc79f7cf2a9d482453f0589d35d3f0a41c
Component: engine
2016-07-08 16:25:21 -04:00
ffff54ffda Fix 'make docker-py' error
Signed-off-by: Yanqiang Miao <miao.yanqiang@zte.com.cn>
Upstream-commit: bbfda85261173b556c8e38930fd7dfff679e36cd
Component: engine
2016-07-07 10:00:22 +08:00
c419d9316f Modify comment of Makefile
Signed-off-by: Yanqiang Miao <miao.yanqiang@zte.com.cn>
Upstream-commit: 38550d27f86bce3bdeaf22093cde491efa38efc6
Component: engine
2016-07-02 11:23:03 +08:00
56f0d7968e Add make install task
This installs docker and dockerd to `$DOCKER_MAKE_INSTALL_PREFIX/bin`, which
defaults to `/usr/local/bin`

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 9bb54f89ad26015c79dab7c5ac210cb846e0713b
Component: engine
2016-06-03 12:08:33 +02:00
b24dc50f14 Makefile: clean git branch before building
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
Upstream-commit: a4192471cd6d6012a66c19a635a11c7f6139d683
Component: engine
2016-05-08 11:52:38 +02:00
dcd6f9747a Build two binaries client and daemon.
Add a proxy to support 'docker daemon'
Fix configFile option, and remove a test that is no longer relevant.
Remove daemon build tag.
Remove DOCKER_CLIENTONLY from build scripts.

Signed-off-by: Daniel Nephin <dnephin@docker.com>

Change docker-daemon to dockerd.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
Upstream-commit: 9e7651db4d464649bc32cf346fdee8c6900ebe0f
Component: engine
2016-04-22 11:26:01 -04:00
ad2c68fb8e Build: pass through DOCKER_GITCOMMIT
This is useful if you want to build Docker when the .git directory is
not present.

Signed-off-by: Thomas Leonard <thomas.leonard@docker.com>
Upstream-commit: 1aa9369499783b25c64737868bb51fdbf9c84f6d
Component: engine
2016-04-14 12:16:16 +01:00
0038ff8590 Fixing a typo in Makefile
A typo is present in the new awesome `make help`, fixing that.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 3785844c5bdd57ded9a6410579e3a356b126c26e
Component: engine
2016-04-07 16:10:09 +02:00
64c1d67e0a remove docker info warnings (if any) from Makefile
Signed-off-by: Victor Vieux <vieux@docker.com>
Upstream-commit: b967e381aac05bd309a0ce9eb2f0c46d4a60d8a7
Component: engine
2016-04-06 16:57:33 -07:00
3791d8a070 add make help
Signed-off-by: Victor Vieux <vieux@docker.com>
Upstream-commit: c72b51b09c2a51ef82b00a8ab69002088f2f3249
Component: engine
2016-04-06 16:57:28 -07:00
5d96f48931 Merge pull request #21691 from tonistiigi/fix-gccgo-make
Fix building gccgo from makefile
Upstream-commit: 76aefc18f988d1c21382e3be88edcb6c99a91ea7
Component: engine
2016-04-06 17:31:59 -04:00