Commit Graph

434 Commits

Author SHA1 Message Date
Joffrey F dc198be26c Don't break when parsing unknown config keys
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-09 12:08:34 -08:00
Joffrey F fea32eb983 Merge branch 'VolumeBind' of https://github.com/keloyang/docker-py into keloyang-VolumeBind 2016-02-08 11:36:09 -08:00
Joffrey F 8bdaffc2e7 Merge pull request #920 from docker/ssl_version_simpler
Remove obsolete SSL version computation
2016-02-05 12:41:02 -08:00
Mike Dougherty 387db11009 Re-write kwargs_from_env to handle TLS options better
This more closely matches the way the docker client interprets the
relevant environment variables. Among other things, it's now possible to
set DOCKER_TLS_VERIFY=false.

Signed-off-by: Mike Dougherty <mike.dougherty@docker.com>
2016-02-04 17:13:09 -08:00
Spencer Rinehart fca622cad7 Add support for shm_size.
--shm-size was added to Docker in 1.10 via docker/docker#16168.  See
docker/compose#2823 for more details.

Signed-off-by: Spencer Rinehart <anubis@overthemonkey.com>
2016-02-04 12:33:05 -06:00
yangshukui f4b3a1bddd create tempfile in VolumeBindTest for non-auto-creating of docker
Signed-off-by: yangshukui <yangshukui@huawei.com>
2016-02-04 15:49:15 +08:00
Joffrey F b808cc45b4 Remove obsolete SSL version computation
Recent versions of urllib3 (including the one packaged by requests)
will automatically reject SSLv2/3.
Additional test to check urllib3's behavior (mostly for release/packaging)

Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-03 17:50:52 -08:00
Joffrey F bb94fe7a8c Support unspecified protocol in base_url when using TLS
(assume HTTPS)

Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-28 16:25:23 -08:00
Aanand Prasad 403d271cc2 Raise exceptions for API errors on network connect/disconnect
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-25 18:19:32 +00:00
Aanand Prasad 01a754a7f7 Support links when creating containers or connecting to networks
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-20 17:47:45 +00:00
Joffrey F eb1f24a1fc Merge pull request #880 from docker/813-parse-float-bytes
Handle 64-bit integer values in parse_bytes
2016-01-18 14:37:34 -08:00
Pavel Kravchenko 84a72f49e9 Add HttpHeaders support in load_config
Signed-off-by: Pavel Kravchenko <kpavel@il.ibm.com>
2016-01-18 14:29:31 -08:00
Joffrey F cd66f6c6cd parse_bytes: Add ability to handle 64-bit integers in py2
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-18 13:53:52 -08:00
Joffrey F f9b04c1026 Improve host devices support
Add unit tests for utils.parse_devices
Rewrite documentation
Support dict and string format for device declaration

Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-18 11:38:32 -08:00
Aanand Prasad 21a5a0a049 Normalise/fix networking API JSON keys
- Use CamelCase
- `auxaddresses` -> `AuxiliaryAddresses`

Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-18 18:41:18 +00:00
Aanand Prasad d00a5bb086 Implement support for network-scoped aliases
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-14 18:19:35 +00:00
Aanand Prasad 62d9964cc1 Merge pull request #818 from rmb938/patch-1
allow custom ipam options when creating networks
2016-01-05 12:55:45 +00:00
Ryan Belgrave 67a29441c4 allow custom ipam options when creating networks
Signed-off-by: Ryan Belgrave <rmb1993@gmail.com>
2016-01-04 18:57:11 -05:00
wenchma c424148853 Update docker network inspect test
This is based on https://github.com/docker/docker/pull/18928

Related to docker/docker#18626

Signed-off-by: Wen Cheng Ma <wenchma@cn.ibm.com>
2015-12-30 10:43:02 +08:00
Joffrey F 8b322aea2b Don't expect non-zero exit code when stopping a container
Signed-off-by: Joffrey F <joffrey@docker.com>
2015-12-23 13:01:05 -08:00
Aanand Prasad 9deffc45a1 Merge pull request #863 from thomasboyt/fast-exclude-paths
Don't descend into ignored directories when building context
2015-12-16 16:59:12 +00:00
Aanand Prasad 25b188440a Treat 'index.docker.io' repo names as 'docker.io'
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2015-12-10 12:42:54 +00:00
Aanand Prasad 9b890c4540 Refactor resolve_authconfig tests
The structure of the fake config dictionary was not reflective of what
actual parsed config looks like.

Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2015-12-10 12:42:54 +00:00
Sumit Sahrawat 2981d013a5 Fix remove_volume return value
Signed-off-by: Sumit Sahrawat <sumit.sahrawat.apm13@iitbhu.ac.in>
2015-12-10 10:29:11 +05:30
Sumit Sahrawat bd948be7d9 Allow providing options when creating networks
Following the spec:

    http://docs.docker.com/engine/reference/api/docker_remote_api_v1.21/#create-a-network

I have added an Options argument to create_network.

This opens up the possibility of creating isolated containers with no
internet access programmatically. We require such facilities in
https://github.com/jupyter/tmpnb/issues/187.

Signed-off-by: Sumit Sahrawat <sumit.sahrawat.apm13@iitbhu.ac.in>
2015-12-10 10:29:11 +05:30
Joffrey F 0f091747ec Merge pull request #868 from jstewmon/config-stop-signal
added stop_signal to create container config
2015-12-08 12:47:31 -08:00
Thomas Boyt a49166abf2 Improve get_paths performance by not descending into ignored directories
Signed-off-by: Thomas Boyt <thomas@ledgerx.com>
2015-12-08 11:26:25 -05:00
Dustin Falgout e0c6ec0343 incorporate feedback
Signed-off-by: Dustin Falgout <dustin@falgout.us>
2015-12-04 01:27:44 -06:00
Dustin Falgout e0365fcbfb Use new methods to raise exceptions in create_host_config.
Added tests for the new methods.
Closes #840

Signed-off-by: Dustin Falgout <dustin@falgout.us>
2015-12-03 17:19:59 -06:00
Jonathan Stewmon 31b1b53f7f added stop_signal to create container config
Signed-off-by: Jonathan Stewmon <jstewmon@rmn.com>
2015-12-03 14:31:51 -06:00
Tomas Tomecek a9a538abaf allow interactive exec
Signed-off-by: Tomas Tomecek <ttomecek@redhat.com>
2015-12-03 11:07:11 +01:00
Tomas Tomecek 55b67acb5b tests,integration: ensure container is removed if start fails
Signed-off-by: Tomas Tomecek <ttomecek@redhat.com>
2015-12-02 09:46:02 +01:00
Nicolas Delaby 05fd8dfb41 fix typo filter param for `volumes`
https://docs.docker.com/engine/reference/api/docker_remote_api_v1.21/#list-volumes

Signed-off-by: Nicolas Delaby <nicolas.delaby@lock8.me>
2015-12-01 15:06:01 +01:00
Joffrey F 00c0baf40f Add tests for new cases covered by parse_repository_tag
Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-24 12:16:00 -08:00
Joffrey F 6d0e2d69d5 Update auth.resolve_repository_name
More relaxed version that matches the constraints imposed by the
current version of the docker daemon.
Few unit tests to verify the new cases.
Client.pull was trying to set the tag value when it wasn't supposed
to, fixed now.
utils.parse_repository_tag is simpler and supports @sha... notation

Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-23 18:43:02 -08:00
Joffrey F 73b51400a1 Fix integration-dind-ssl make task
Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-18 15:41:32 -08:00
Joffrey F de617375f1 Move methods/classes used by all integration tests to helpers.py
Ensure setup_module is called at session level, making the test
suite not order dependent. Test files can be invoked independently.

Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-18 15:40:54 -08:00
Joffrey F 64eac0b71c Wrong key name in stats test
Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-18 14:47:48 -08:00
Joffrey F dfcc1d87bf Merge branch 'oom-kill-disable-pr' of https://github.com/schu/docker-py into schu-oom-kill-disable-pr 2015-11-18 14:35:54 -08:00
Joffrey F 9ed721957a Merge pull request #832 from aebm/master
Fix #627
2015-11-18 14:29:00 -08:00
Daniel Nephin 0284eadaff Merge pull request #805 from sourcelair/enhancement/stats-no-stream
Add support for non-stream stats of containers
2015-11-17 10:47:28 -05:00
Daniel Nephin 4e441b2a6b Merge pull request #834 from lots0logs/814-host-config-mem-swap
Add support for MemorySwappiness to client.create_host_config()
2015-11-16 11:37:15 -05:00
Joffrey F ac148393b1 Merge pull request #851 from docker/remove-ci-transition-files
Remove unused files
2015-11-12 11:51:32 -08:00
Joffrey F c3197dcce7 Merge pull request #850 from docker/mnowster-test-no-log-driver-specified
Rebased #798
2015-11-12 11:23:16 -08:00
Joffrey F c622ff64b9 Remove unused files
Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-12 11:21:37 -08:00
Joffrey F b0bb4ff3a4 Merge branch 'test-no-log-driver-specified' of https://github.com/mnowster/docker-py into mnowster-test-no-log-driver-specified
Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-12 11:11:51 -08:00
Daniel Nephin 6e73f04acc Merge pull request #796 from v-boyko/feature/logs_since
Support the 'since' option in the 'containers/<id>/logs' endpoint (API upgrade)
2015-11-12 14:07:54 -05:00
Joffrey F c89d366827 Merge pull request #848 from docker/845-fix
Client.logs(tail=0) now shows no past logs (expected behavior)
2015-11-12 10:54:51 -08:00
Joffrey F 0e13a0d7fd Client.logs(tail=0) now shows no past logs (expected behavior)
Add test confirming the new behavior.

Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-12 10:50:01 -08:00
Joffrey F fe858f5ecc Add build integration test checking stderr shows up in stream
Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-11 17:14:03 -08:00