summaryrefslogtreecommitdiff
path: root/tests/unit/models_containers_test.py
Commit message (Collapse)AuthorAgeFilesLines
* Disable compression by default when using get_archive methodNiklas Saari2020-08-101-1/+1
| | | | Signed-off-by: Niklas Saari <niklas.saari@tutanota.com>
* Move volume_driver to RUN_HOST_CONFIG_KWARGSHannes Ljungberg2019-03-231-1/+1
| | | | | | Fixes #2271 Signed-off-by: Hannes Ljungberg <hannes@5monkeys.se>
* Remove use_config_proxy from exec. Add use_config_proxy docs to DockerClientproxy_env_fixesJoffrey F2019-01-091-2/+2
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* By default, disable proxy supportCorentin Henry2019-01-091-2/+2
| | | | | | This is to avoid a breaking change Signed-off-by: Corentin Henry <corentinhenry@gmail.com>
* Merge branch 'master' of https://github.com/little-dude/docker-py into ↵Joffrey F2018-11-301-2/+4
|\ | | | | | | little-dude-master
| * implement stream demultiplexing for exec commandsCorentin Henry2018-11-271-2/+4
| | | | | | | | | | | | fixes https://github.com/docker/docker-py/issues/1952 Signed-off-by: Corentin Henry <corentinhenry@gmail.com>
* | Update DockerClient.images.pull to always stream responseadw1n-i2116Joffrey F2018-11-281-2/+3
| | | | | | | | | | | | Also raise a warning when users attempt to specify the "stream" parameter Signed-off-by: Joffrey F <joffrey@docker.com>
* | Fix pulling images with `stream=True`adw1n2018-11-281-1/+2
|/ | | | | | | | | | | | | | | | | Pulling an image with option `stream=True` like this: ``` client.api.pull('docker.io/user/repo_name', tag='latest', stream=True) ``` without consuming the generator oftentimes results in premature drop of the connection. Docker daemon tries to send progress of pulling the image to the client, but it encounters an error (broken pipe) and therefore cancells the pull action: ``` Thread 1 "dockerd-dev" received signal SIGPIPE, Broken pipe. ERRO[2018-09-03T05:12:35.746497638+02:00] Not continuing with pull after error: context canceled ``` As described in issue #2116, even though client receives response with status code 200, image is not pulled. Closes #2116 Signed-off-by: Przemysław Adamek <adw1n@users.noreply.github.com>
* Add support for `uts_mode` parameter in `Client.create_host_config`.Marco Trillo2018-06-291-0/+2
| | | | | | | | | | This parameter allows to set the UTS namespace of the container, as in the `--uts=X` Docker CLI parameter: <https://docs.docker.com/engine/reference/run/#uts-settings---uts> The only allowed value, if set, is "host". Signed-off-by: Marco Trillo <martri@arantia.com> Signed-off-by: Diego Alvarez <dyako.developer@gmail.com>
* Add ignore_removed param to containers.list() to control whether toJoffrey F2018-04-251-0/+12
| | | | | | raise or ignore NotFound Signed-off-by: Joffrey F <joffrey@docker.com>
* Add chunk_size parameter to data downloading methods (export, get_archive, save)1352-data_stream_controlJoffrey F2018-02-141-2/+7
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Update wait to always return a dictwait_returnJoffrey F2018-01-311-3/+3
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Correctly parse volumes with Windows paths1884-create_volumes_win32Joffrey F2018-01-311-2/+5
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Use pytest assertspytest-assertsJoffrey F2018-01-301-7/+8
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Return tuple instead of dict in exec_runJoffrey F2018-01-261-4/+6
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Merge branch 'add_exit_code_to_exec_run' of ↵Joffrey F2018-01-261-0/+11
|\ | | | | | | https://github.com/hnq90/docker-py into hnq90-add_exit_code_to_exec_run
| * Add exit code to exec_runHuyNQ2017-11-131-0/+11
| | | | | | | | Signed-off-by: HuyNQ <huy@huynq.net>
* | Bump default API version to 1.35Joffrey F2018-01-261-1/+2
| | | | | | | | | | | | | | | | | | Add ContainerSpec.isolation support Add until support in logs Add condition support in wait Add workdir support in exec_create Signed-off-by: Joffrey F <joffrey@docker.com>
* | Add support for experimental platform flag in build and pull1855-platform-optionJoffrey F2018-01-231-1/+1
| | | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* | Retrieve container logs before container exits / is removed1813-run-autoremoveJoffrey F2017-12-141-4/+3
|/ | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Allow detach and remove for api version >= 1.25 and use auto_remove when ↵David Steines2017-08-171-0/+30
| | | | | | both are set. Continue raising an exception for api versions <1.25. Signed-off-by: David Steines <d.steines@gmail.com>
* Replace erroneous networks argument in containers.run with singular1433-run-networksJoffrey F2017-05-121-3/+2
| | | | | | | | network equivalent. Small docfixes Signed-off-by: Joffrey F <joffrey@docker.com>
* Include tag in images.get after pulling if provided separately1585-pull-tagJoffrey F2017-05-091-1/+1
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Merge branch 'add-env-support-to-exec' of ↵Joffrey F2017-05-021-1/+1
|\ | | | | | | | | | | https://github.com/TomasTomecek/docker-py into TomasTomecek-add-env-support-to-exec Signed-off-by: Joffrey F <joffrey@docker.com>
| * exec: add support for `Env`Tomas Tomecek2017-04-291-1/+1
| | | | | | | | Signed-off-by: Tomas Tomecek <ttomecek@redhat.com>
* | Fix typo s/CpuSetCpus/CpusetCpus/Dan Liew2017-05-011-1/+1
|/ | | | | | | | | According to Docker's API documentation [1]. The parameter name is `CpusetCpus` not `CpuSetCpus`. [1] https://docs.docker.com/engine/api/v1.25/#operation/ContainerCreate Signed-off-by: Dan Liew <daniel.liew@imperial.ac.uk>
* Adds an 'image' property to the container modelFrank Sachsenheim2017-04-151-0/+5
| | | | Signed-off-by: Frank Sachsenheim <funkyfuture@riseup.net>
* Adds a 'labels' property to the container modelFrank Sachsenheim2017-04-151-0/+5
| | | | | | | | The Docker API seems to respond with a 'null' value for the 'Labels' attribute from containers that were created with older Docker versions. An empty dictionary is returned in this case. Signed-off-by: Frank Sachsenheim <funkyfuture@riseup.net>
* Fix passing volumes to run with no host pathBen Firshman2017-02-071-1/+11
| | | | | | | | | Technically we shouldn't be passing them as binds, but the daemon doesn't seem to mind. Fixes #1380 Signed-off-by: Ben Firshman <ben@firshman.co.uk>
* Fix volume path passed by run to create_containerBen Firshman2017-02-071-1/+3
| | | | | | | | | | | | Seems like this is pretty much ignored by Docker, so it wasn't causing any visible issues, except when a volume name was used instead of a path. Also, added integration tests. Ref #1380 Signed-off-by: Ben Firshman <ben@firshman.co.uk>
* Add new user-focused APIBen Firshman2016-11-221-0/+465
See #1086 Signed-off-by: Ben Firshman <ben@firshman.co.uk>