summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Bump 4.1.04.1.0-releaseChristopher Crone2019-10-032-1/+22
| | | | Signed-off-by: Christopher Crone <christopher.crone@docker.com>
* Bump pytest to 4.3.1Kir Kolyshkin2019-10-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Pytest 4.3.1 includes the fix from https://github.com/pytest-dev/pytest/pull/4795 which should fix the following failure: > INFO: Building docker-sdk-python3:4.0.2... > sha256:c7a40413c985b6e75df324fae39b1c30cb78a25df71b7892f1a4a15449537fb3 > INFO: Starting docker-py tests... > Traceback (most recent call last): > File "/usr/local/bin/pytest", line 10, in <module> > sys.exit(main()) > File "/usr/local/lib/python3.6/site-packages/_pytest/config/__init__.py", line 61, in main > config = _prepareconfig(args, plugins) > File "/usr/local/lib/python3.6/site-packages/_pytest/config/__init__.py", line 182, in _prepareconfig > config = get_config() > File "/usr/local/lib/python3.6/site-packages/_pytest/config/__init__.py", line 156, in get_config > pluginmanager.import_plugin(spec) > File "/usr/local/lib/python3.6/site-packages/_pytest/config/__init__.py", line 530, in import_plugin > __import__(importspec) > File "/usr/local/lib/python3.6/site-packages/_pytest/tmpdir.py", line 25, in <module> > class TempPathFactory(object): > File "/usr/local/lib/python3.6/site-packages/_pytest/tmpdir.py", line 35, in TempPathFactory > lambda p: Path(os.path.abspath(six.text_type(p))) > TypeError: attrib() got an unexpected keyword argument 'convert' > Sending interrupt signal to process > Terminated > script returned exit code 143 Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
* Fix broken test due to BUSYBOX -> TEST_IMG renameSebastiaan van Stijn2019-10-031-1/+1
| | | | | | | | | | | | | | | | | | | | The BUSYBOX variable was renamed to TEST_IMG in 54b48a9b7ab59b4dcf49acf49ddf52035ba3ea08, however 0ddf428b6ce7accdac3506b45047df2cb72941ec got merged after that change, but was out of date, and therefore caused the tests to fail: ``` =================================== FAILURES =================================== ________ ServiceTest.test_create_service_with_network_attachment_config ________ tests/integration/api_service_test.py:379: in test_create_service_with_network_attachment_config container_spec = docker.types.ContainerSpec(BUSYBOX, ['true']) E NameError: global name 'BUSYBOX' is not defined ``` Fix the test by using the correct variable name. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* Correctly reference SecretReferenceHannes Ljungberg2019-10-031-1/+1
| | | | Signed-off-by: Hannes Ljungberg <hannes@5monkeys.se>
* Correctly reference ConfigReferenceHannes Ljungberg2019-10-031-2/+3
| | | | Signed-off-by: Hannes Ljungberg <hannes@5monkeys.se>
* Add NetworkAttachmentConfig typeHannes Ljungberg2019-10-036-9/+60
| | | | Signed-off-by: Hannes Ljungberg <hannes@5monkeys.se>
* Jenkinsfile: update python 3.6 -> 3.7Sebastiaan van Stijn2019-10-031-1/+1
| | | | Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* Jenkinsfile: update API version matrix; set default to v1.40Sebastiaan van Stijn2019-10-031-3/+5
| | | | | | | | | | - Added new entry for Docker 19.03 - Removed obsolete engine versions that reached EOL (both as Community Edition and Enterprise Edition) - Set the fallback/default API version to v1.40, which corresponds with Docker 19.03 (current release) Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* Amends the docs concerning multiple label filtersFrank Sachsenheim2019-10-036-6/+12
| | | | | | Closes #2338 Signed-off-by: Frank Sachsenheim <funkyfuture@riseup.net>
* test/Dockerfile: allow using a mirror for the apt repositorySebastiaan van Stijn2019-10-032-2/+7
| | | | | | | | | | | | | | | | | | | | | With this change applied, the default debian package repository can be replaced with a mirror; ``` make APT_MIRROR=cdn-fastly.deb.debian.org build-py3 ... Step 5/19 : RUN apt-get update && apt-get -y install gnupg2 pass curl ---> Running in 01c1101a0bd0 Get:1 http://cdn-fastly.deb.debian.org/debian buster InRelease [118 kB] Get:2 http://cdn-fastly.deb.debian.org/debian-security buster/updates InRelease [39.1 kB] Get:3 http://cdn-fastly.deb.debian.org/debian buster-updates InRelease [46.8 kB] Get:4 http://cdn-fastly.deb.debian.org/debian buster/main amd64 Packages [7897 kB] Get:5 http://cdn-fastly.deb.debian.org/debian-security buster/updates/main amd64 Packages [22.8 kB] ``` Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* Correct INDEX_URL logic in build.py _set_auth_headersMatt Fluet2019-10-031-1/+2
| | | | Signed-off-by: Matt Fluet <matt.fluet@appian.com>
* pytest: update to v4.2.1 - use xunit2 for compatibility with JenkinsSebastiaan van Stijn2019-10-032-1/+2
| | | | | | | | | - pytest-dev/pytest#3547: `--junitxml` can emit XML compatible with Jenkins xUnit. `junit_family` INI option accepts `legacy|xunit1`, which produces old style output, and `xunit2` that conforms more strictly to https://github.com/jenkinsci/xunit-plugin/blob/xunit-2.3.2/src/main/resources/org/jenkinsci/plugins/xunit/types/model/xsd/junit-10.xsd Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* pytest: set junitxml suite name to "docker-py"Sebastiaan van Stijn2019-10-031-0/+2
| | | | Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* Fix typo in comment. networks => networkRyan McCullagh2019-10-031-1/+1
| | | | Signed-off-by: Ryan McCullagh <ryan@amezmo.com>
* Fix for empty auth keys in config.jsonMatt Fluet2019-10-032-0/+118
| | | | Signed-off-by: Matt Fluet <matt.fluet@appian.com>
* Update alpine version to 3.10, and rename BUSYBOX variableSebastiaan van Stijn2019-10-0312-189/+189
| | | | Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* Adjust `--platform` tests for changes in docker engineSebastiaan van Stijn2019-10-032-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These tests started failing on recent versions of the engine because the error string changed, and due to a regression, the status code for one endpoint changed from a 400 to a 500. On Docker 18.03: The `docker build` case properly returns a 400, and "invalid platform" as error string; ```bash docker build --platform=foobar -<<EOF FROM busybox EOF Sending build context to Docker daemon 2.048kB Error response from daemon: invalid platform: invalid platform os "foobar" ``` ``` DEBU[2019-07-15T12:17:22.745511870Z] Calling GET /_ping DEBU[2019-07-15T12:17:22.748224796Z] Calling POST /session DEBU[2019-07-15T12:17:22.748692282Z] Calling POST /v1.37/build?buildargs=%7B%7D&cachefrom=%5B%5D&cgroupparent=&cpuperiod=0&cpuquota=0&cpusetcpus=&cpusetmems=&cpushares=0&dockerfile=Dockerfile&labels=%7B%7D&memory=0&memswap=0&networkmode=default&platform=foobar&rm=1&session=d7b6ceba9d8d0aed67a805528554feb5285781fe888a4bf4e0c15cb09bffd614&shmsize=0&target=&ulimits=null ``` The `docker pull --platform=foobar hello-world:latest` case incorrectly returns a 500 ``` DEBU[2019-07-15T12:16:08.744827612Z] Calling POST /v1.37/images/create?fromImage=hello-world&platform=foobar&tag=latest DEBU[2019-07-15T12:16:08.745594874Z] FIXME: Got an API for which error does not match any expected type!!!: invalid platform: invalid platform os "foobar" error_type="*errors.errorString" module=api ERRO[2019-07-15T12:16:08.745916686Z] Handler for POST /v1.37/images/create returned error: invalid platform: invalid platform os "foobar" DEBU[2019-07-15T12:16:08.746191172Z] FIXME: Got an API for which error does not match any expected type!!!: invalid platform: invalid platform os "foobar" error_type="*errors.errorString" module=api ``` On Docker 18.09; ```bash docker build --platform=foobar -<<EOF FROM busybox EOF Error response from daemon: "foobar": unknown operating system or architecture: invalid argument ``` Which incorrectly returns a 500 status; ``` DEBU[2019-07-15T11:59:20.687268380Z] Calling POST /v1.39/build?buildargs=%7B%7D&cachefrom=%5B%5D&cgroupparent=&cpuperiod=0&cpuquota=0&cpusetcpus=&cpusetmems=&cpushares=0&dockerfile=Dockerfile&labels=%7B%7D&memory=0&memswap=0&networkmode=default&platform=foobar&rm=1&session=jko7kejjvs93judyfnq7shoda&shmsize=0&target=&ulimits=null&version=1 DEBU[2019-07-15T11:59:20.687282279Z] Calling POST /session INFO[2019-07-15T11:59:20.687761392Z] parsed scheme: "" module=grpc INFO[2019-07-15T11:59:20.687833668Z] scheme "" not registered, fallback to default scheme module=grpc INFO[2019-07-15T11:59:20.688017578Z] ccResolverWrapper: sending new addresses to cc: [{ 0 <nil>}] module=grpc INFO[2019-07-15T11:59:20.688270160Z] ClientConn switching balancer to "pick_first" module=grpc INFO[2019-07-15T11:59:20.688353083Z] pickfirstBalancer: HandleSubConnStateChange: 0xc4209b0630, CONNECTING module=grpc INFO[2019-07-15T11:59:20.688985698Z] pickfirstBalancer: HandleSubConnStateChange: 0xc4209b0630, READY module=grpc DEBU[2019-07-15T11:59:20.812700550Z] client is session enabled DEBU[2019-07-15T11:59:20.813139288Z] FIXME: Got an API for which error does not match any expected type!!!: invalid argument github.com/docker/docker/vendor/github.com/containerd/containerd/errdefs.init /go/src/github.com/docker/docker/vendor/github.com/containerd/containerd/errdefs/errors.go:40 github.com/docker/docker/vendor/github.com/containerd/containerd/content.init <autogenerated>:1 github.com/docker/docker/builder/builder-next.init <autogenerated>:1 github.com/docker/docker/api/server/backend/build.init <autogenerated>:1 main.init <autogenerated>:1 runtime.main /usr/local/go/src/runtime/proc.go:186 runtime.goexit /usr/local/go/src/runtime/asm_amd64.s:2361 error_type="*errors.fundamental" module=api ERRO[2019-07-15T11:59:20.813210677Z] Handler for POST /v1.39/build returned error: "foobar": unknown operating system or architecture: invalid argument DEBU[2019-07-15T11:59:20.813276737Z] FIXME: Got an API for which error does not match any expected type!!!: invalid argument github.com/docker/docker/vendor/github.com/containerd/containerd/errdefs.init /go/src/github.com/docker/docker/vendor/github.com/containerd/containerd/errdefs/errors.go:40 github.com/docker/docker/vendor/github.com/containerd/containerd/content.init <autogenerated>:1 github.com/docker/docker/builder/builder-next.init <autogenerated>:1 github.com/docker/docker/api/server/backend/build.init <autogenerated>:1 main.init <autogenerated>:1 runtime.main /usr/local/go/src/runtime/proc.go:186 runtime.goexit /usr/local/go/src/runtime/asm_amd64.s:2361 error_type="*errors.fundamental" module=api ``` Same for the `docker pull --platform=foobar hello-world:latest` case: ```bash docker pull --platform=foobar hello-world:latest Error response from daemon: "foobar": unknown operating system or architecture: invalid argument ``` ``` DEBU[2019-07-15T12:00:18.812995330Z] Calling POST /v1.39/images/create?fromImage=hello-world&platform=foobar&tag=latest DEBU[2019-07-15T12:00:18.813229172Z] FIXME: Got an API for which error does not match any expected type!!!: invalid argument github.com/docker/docker/vendor/github.com/containerd/containerd/errdefs.init /go/src/github.com/docker/docker/vendor/github.com/containerd/containerd/errdefs/errors.go:40 github.com/docker/docker/vendor/github.com/containerd/containerd/content.init <autogenerated>:1 github.com/docker/docker/builder/builder-next.init <autogenerated>:1 github.com/docker/docker/api/server/backend/build.init <autogenerated>:1 main.init <autogenerated>:1 runtime.main /usr/local/go/src/runtime/proc.go:186 runtime.goexit /usr/local/go/src/runtime/asm_amd64.s:2361 error_type="*errors.fundamental" module=api ERRO[2019-07-15T12:00:18.813365546Z] Handler for POST /v1.39/images/create returned error: "foobar": unknown operating system or architecture: invalid argument DEBU[2019-07-15T12:00:18.813461428Z] FIXME: Got an API for which error does not match any expected type!!!: invalid argument github.com/docker/docker/vendor/github.com/containerd/containerd/errdefs.init /go/src/github.com/docker/docker/vendor/github.com/containerd/containerd/errdefs/errors.go:40 github.com/docker/docker/vendor/github.com/containerd/containerd/content.init <autogenerated>:1 github.com/docker/docker/builder/builder-next.init <autogenerated>:1 github.com/docker/docker/api/server/backend/build.init <autogenerated>:1 main.init <autogenerated>:1 runtime.main /usr/local/go/src/runtime/proc.go:186 runtime.goexit /usr/local/go/src/runtime/asm_amd64.s:2361 error_type="*errors.fundamental" module=api ``` Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* xfail test_init_swarm_data_path_addrSebastiaan van Stijn2019-10-031-0/+1
| | | | | | | | | | | This test can fail if `eth0` has multiple IP addresses; E docker.errors.APIError: 400 Client Error: Bad Request ("interface eth0 has more than one IPv6 address (2001:db8:1::242:ac11:2 and fe80::42:acff:fe11:2)") Which is not a failiure, but depends on the environment that the test is run in. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* Update credentials-helpers to v0.6.3Sebastiaan van Stijn2019-10-031-1/+1
| | | | | | | full diff: https://github.com/docker/docker-credential-helpers/compare/v0.6.2...v0.6.3 Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* Add documentation to argument 'mem_reservation'.Francis Laniel2019-10-032-1/+2
| | | | | | | | | | | | | | The documentation was added for function ContainerCollection::run and ContainerApiMixin::create_host_config. Signed-off-by: Francis Laniel <francis.laniel@lip6.fr> Add documentation to argument 'mem_reservation'. The documentation was added for function ContainerCollection::run and ContainerApiMixin::create_host_config. Signed-off-by: Francis Laniel <francis.laniel@lip6.fr>
* Update to python 3.7 (buster) and use build-argsSebastiaan van Stijn2019-10-035-7/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The build arg can be used to either test different versions, but also makes it easier to "grep" when upgrading versions. The output format of `gpg2 --list-secret-keys` changed in the version installed on Buster, so `grep` was replaced with `awk` to address the new output format; Debian Jessie: gpg2 --no-auto-check-trustdb --list-secret-keys /root/.gnupg/secring.gpg ------------------------ sec 1024D/A7B21401 2018-04-25 uid Sakuya Izayoi <sakuya@gensokyo.jp> ssb 1024g/C235E4CE 2018-04-25 Debian Buster: gpg2 --no-auto-check-trustdb --list-secret-keys /root/.gnupg/pubring.kbx ------------------------ sec dsa1024 2018-04-25 [SCA] 9781B87DAB042E6FD51388A5464ED987A7B21401 uid [ultimate] Sakuya Izayoi <sakuya@gensokyo.jp> ssb elg1024 2018-04-25 [E] Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* Bump devDjordje Lukic2019-10-031-1/+1
| | | | Signed-off-by: Djordje Lukic <djordje.lukic@docker.com>
* Update credentials-helpers to v0.6.2Sebastiaan van Stijn2019-10-031-1/+1
| | | | Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
* Remove exec detach testMichael Crosby2019-10-031-18/+0
| | | | | | Forking off an exec process and detaching isn't a supported method Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
* Merge pull request #2365 from docker/4.0.2-release4.0.2Djordje Lukic2019-06-205-6/+22
|\ | | | | 4.0.2 release
| * Bump 4.0.24.0.2-releaseDjordje Lukic2019-06-202-1/+15
| | | | | | | | Signed-off-by: Djordje Lukic <djordje.lukic@docker.com>
| * Bump websocket-client -> 0.56.0Djordje Lukic2019-06-201-1/+1
| | | | | | | | Signed-off-by: Djordje Lukic <djordje.lukic@docker.com>
| * Clean up healtcheck.py docsKajetan Champlewski2019-06-201-3/+3
| | | | | | | | Signed-off-by: Kajetan Champlewski <contact@kajetan.ch>
| * Handle str in setter for test.Kajetan Champlewski2019-06-201-0/+2
| | | | | | | | Signed-off-by: Kajetan Champlewski <contact@kajetan.ch>
| * Fix documentation for inspect_secret referring to removal.Kajetan Champlewski2019-06-201-1/+1
| | | | | | | | Signed-off-by: Kajetan Champlewski <contact@kajetan.ch>
| * dev versionJoffrey F2019-06-201-1/+1
|/ | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Merge pull request #2348 from docker/4.0.1-release4.0.1Joffrey F2019-05-185-6/+30
|\ | | | | 4.0.1 release
| * Changelog 4.0.14.0.1-releaseJoffrey F2019-05-181-0/+14
| | | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
| * Bump 4.0.1Joffrey F2019-05-181-1/+1
| | | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
| * Version bumpJoffrey F2019-05-181-1/+1
| | | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
| * Change os.errno to errno for py3.7 compatibilitySimon Gurcke2019-05-181-3/+3
| | | | | | | | Signed-off-by: Simon Gurcke <simon@gurcke.de>
| * Add readthedocs configJoffrey F2019-05-181-0/+10
| | | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
| * reference swarm page correctlyBatuhan Taşkaya2019-05-181-2/+2
|/ | | | Signed-off-by: Batuhan Taşkaya <btaskaya33@gmail.com>
* Merge pull request #2331 from docker/4.0.0-release4.0.0Joffrey F2019-05-1851-249/+918
|\ | | | | 4.0.0 release
| * Bump urllib3 -> 1.24.34.0.0-releaseUlysses Souza2019-05-181-1/+1
| | | | | | | | Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
| * Merge branch 'release' into 4.0.0-releaseJoffrey F2019-05-131-0/+1
| |\ | |/ |/| | | Signed-off-by: Joffrey F <joffrey@docker.com>
* | Merge pull request #2299 from ulyssessouza/3.7.2-release3.7.2Ulysses Souza2019-03-286-16/+27
|\ \ | | | | | | Bump 3.7.2 release
| * | Bump 3.7.2Ulysses Souza2019-03-282-1/+12
| | | | | | | | | | | | Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
| * | scripts/version.py: Use regex grouping to extract the versionIan Campbell2019-03-281-7/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `lstrip` and `rstrip` functions take a set of characters to remove, not a prefix/suffix. Thus `rstrip('-x86_64')` will remove any trailing characters in the string `'-x86_64'` in any order (in effect it strips the suffix matching the regex `[-_x468]*`). So with `18.09.4` it removes the `4` suffix resulting in trying to `int('')` later on: Traceback (most recent call last): File "/src/scripts/versions.py", line 80, in <module> main() File "/src/scripts/versions.py", line 73, in main versions, reverse=True, key=operator.attrgetter('order') File "/src/scripts/versions.py", line 52, in order return (int(self.major), int(self.minor), int(self.patch)) + stage ValueError: invalid literal for int() with base 10: '' Since we no longer need to check for the arch suffix (since it no longer appears in the URLs we are traversing) we could just drop the `rstrip` and invent a local prefix stripping helper to replace `lstrip('docker-')`. Instead lets take advantage of the behaviour of `re.findall` which is that if the regex contains a single `()` match that will be returned. This lets us match exactly the sub-section of the regex we require. While editing the regex, also ensure that the suffix is precisely `.tgz` and not merely `tgz` by adding an explicit `\.`, previously the literal `.` would be swallowed by the `.*` instead. Signed-off-by: Ian Campbell <ijc@docker.com>
| * | Fix base_url to keep TCP protocolUlysses Souza2019-03-282-7/+9
| | | | | | | | | | | | | | | | | | | | | | | | This fix lets the responsability of changing the protocol to `parse_host` afterwards, letting `base_url` with the original value. Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
| * | Xfail test_attach_stream_and_cancel on TLSUlysses Souza2019-03-281-1/+3
|/ / | | | | | | | | | | This test is quite flaky on ssl integration test Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
| * Update changelog for 4.0.0Joffrey F2019-05-131-0/+37
| | | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
| * Bump version 4.0.0Joffrey F2019-05-131-1/+1
| | | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
| * Bump 3.7.2Ulysses Souza2019-05-131-0/+11
| | | | | | | | Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
| * Xfail test_attach_stream_and_cancel on TLSUlysses Souza2019-05-131-0/+3
| | | | | | | | | | | | This test is quite flaky on ssl integration test Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>