summaryrefslogtreecommitdiff
path: root/docker/utils/utils.py
Commit message (Collapse)AuthorAgeFilesLines
* Do not break when calling format_environment with unicode valuesformat_env_unicode_bugJoffrey F2016-10-121-0/+3
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Pass file object to Tarfile.addfile()Christian Bundy2016-09-271-1/+12
| | | | | | | | | | This resolves an issue where TarFile.gettarinfo() doesn't include the file object, meaning that TarFile.addfile(TarFile.gettarinfo()) doesn't pass the test suite. Instead, this uses an open() within a try...except block to include a file object for each file without passing a file object when the path is a directory. Signed-off-by: Christian Bundy <christianbundy@fraction.io>
* Synthesize executable bit on WindowsSebastian Schwarz2016-09-271-1/+5
| | | | | | | | | | | The build context is tarred up on the client and then sent to the Docker daemon. However Windows permissions don't match the Unix ones. Therefore we have to mark all files as executable when creating a build context on Windows, like `docker build` already does: https://github.com/docker/docker/issues/11047. Signed-off-by: Sebastian Schwarz <seschwar@gmail.com>
* Fix licensesBen Firshman2016-09-051-14/+0
| | | | | | | * Complete main LICENSE * Remove unnecessary licenses from individual files Signed-off-by: Ben Firshman <ben@firshman.co.uk>
* Merge pull request #1168 from docker/aiden0z-masterJoffrey F2016-08-251-1/+8
|\ | | | | Support pids_limit in HostConfig
| * Merge branch 'master' of https://github.com/aiden0z/docker-py into ↵Joffrey F2016-08-231-1/+8
| |\ | | | | | | | | | aiden0z-master
| | * fix #1094, support PidsLimit in host configAiden Luo2016-06-171-1/+8
| | | | | | | | | | | | Signed-off-by: Aiden Luo <aiden0xz@gmail.com>
* | | Fix creating containers with env vars with unicode charactersfermayo2016-08-251-1/+1
|/ / | | | | | | Signed-off-by: Fernando Mayo <fernando@docker.com>
* | support MemoryReservation and KernelMemoryKay Yan2016-08-231-2/+16
| | | | | | | | Signed-off-by: Kay Yan <kay.yan@daocloud.io>
* | Merge branch 'master' of https://github.com/srikalyan/docker-py into ↵Joffrey F2016-08-231-1/+9
|\ \ | | | | | | | | | srikalyan-master
| * | Added support for user namespace.Srikalyan Swayampakula2016-06-301-1/+9
| | | | | | | | | | | | Signed-off-by: Srikalyan Swayampakula <srikalyansswayam@gmail.com>
* | | Merge branch 'jp-cpushares' of https://github.com/joshpurvis/docker-py into ↵Joffrey F2016-08-231-1/+26
|\ \ \ | | | | | | | | | | | | joshpurvis-jp-cpushares
| * | | Move cpu_shares and cpuset_cpu to HostConfig when API >= 1.18Josh Purvis2016-08-151-1/+25
| | | | | | | | | | | | | | | | Signed-off-by: Josh Purvis <joshua.purvis@gmail.com>
* | | | Merge pull request #1131 from Knetic/dnsoptsJoffrey F2016-08-231-1/+7
|\ \ \ \ | | | | | | | | | | Implemented dns_opt support (from api 1.21)
| * | | | Implemented dns_opt support (from api 1.21)George Lester2016-08-071-1/+7
| |/ / / | | | | | | | | | | | | Signed-off-by: George Lester <glester491@gmail.com>
* | | | New docker.types subpackage containing advanced config dictionary typesJoffrey F2016-08-191-1/+1
|/ / / | | | | | | | | | | | | | | | | | | Tests and docs updated to match docker.utils.types has been moved to docker.types Signed-off-by: Joffrey F <joffrey@docker.com>
* | | Add support for sysctl when creating containerJari Takkala2016-08-011-1/+8
| | | | | | | | | | | | | | | | | | Closes #1144 Signed-off-by: Jari Takkala <jtakkala@gmail.com>
* | | Add support for IPv6 docker host connections.1135-ipv6-docker-hostJoffrey F2016-07-271-20/+18
| | | | | | | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* | | Default to npipe address on WindowsAanand Prasad2016-07-261-1/+3
| | | | | | | | | | | | Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
* | | Send LinkLocalIPs as part of IPAMConfig dictionarycompose-3757-linklocal-fixJoffrey F2016-07-251-4/+4
|/ / | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* | Add support for link-local IPs in endpoint config1107-link-local-ipsJoffrey F2016-06-241-1/+9
|/ | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Merge pull request #1066 from yunzhu-li/blkio-controlJoffrey F2016-06-151-2/+58
|\ | | | | Add support for Block IO constraints in HostConfig
| * Add support for Block IO constraints in HostConfigyunzhu-li2016-06-051-2/+58
| | | | | | | | | | | | | | | | | | | | | | | | This adds support for Block IO constraint options: - blkio-weight - blkio-weight-device - device-read-bps - device-write-bps - device-read-iops - device-write-iops Signed-off-by: yunzhu-li <contact@yunzhu.li>
* | Merge pull request #1079 from docker/1024-npipe-supportJoffrey F2016-06-141-3/+6
|\ \ | | | | | | npipe support
| * | Update parse_host and testsJoffrey F2016-06-021-2/+2
| | | | | | | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
| * | Experimental npipe:// supportJoffrey F2016-06-021-1/+4
| |/ | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* | Add ipv[46]_address params to create_endpoint_config.Joffrey F2016-06-131-5/+16
|/ | | | | | Update networks documentation with exhaustive API docs Signed-off-by: Joffrey F <joffrey@docker.com>
* support Python 3.5Thomas Grainger2016-05-191-8/+2
| | | | Signed-off-by: Thomas Grainger <tom.grainger@procensus.com>
* Resolve path traversal in .dockerignore patternsAanand Prasad2016-05-161-0/+3
| | | | Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
* Merge pull request #1004 from klj613/allow-equals-character-in-env-fileJoffrey F2016-04-271-1/+1
|\ | | | | makes it possible to have '=' in the env file
| * makes it possible to have '=' in the env fileKristian Lewis Jones2016-03-221-1/+1
| | | | | | | | | | | | note that the docker command line flag --env-file also allows '=' in the env file Signed-off-by: Kristian Lewis Jones <klj613@kristianlewisjones.com>
* | Add an option to gzip tar files.Michael Sander2016-03-221-2/+2
| | | | | | | | | | | | This can be used to make building much faster. Signed-off-by: speedplane <mes65@cornell.edu>
* | Support OomScoreAdj in host configurationAditya Marella2016-03-221-1/+10
| | | | | | | | Signed-off-by: Aditya Marella <aditya.marella@gmail.com>
* | Support passing an alternate environment dict to kwargs_from_envkwargs_from_env_altJoffrey F2016-03-211-4/+6
|/ | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* If tcp host is provided while TLS is enabled, convert to httpstcp-to-https-parsehostJoffrey F2016-03-171-2/+3
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Don't support tmpfs in API version < 1.22Aanand Prasad2016-03-161-0/+2
| | | | Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
* Clarify error messages when bad values are passed in for tmpfsAanand Prasad2016-03-161-2/+4
| | | | Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
* Add support for Tmpfs declaration in Hostconfig.Jan Losinski2016-03-161-1/+31
| | | | | | | This adds support for the Tmpfs option introduced in Docker 1.10. See: https://github.com/docker/docker/pull/13587 Signed-off-by: Jan Losinski <losinski@wh2.tu-dresden.de>
* Fix enable_tls issue #984Joffrey F2016-03-111-4/+4
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Merge pull request #916 from docker/container_update_featureJoffrey F2016-02-241-39/+35
|\ | | | | Support for container limits update
| * Improve parse_bytes util methodcontainer_update_featureJoffrey F2016-02-231-39/+35
| | | | | | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* | Fix env vars with empty values.Daniel Nephin2016-02-241-1/+1
| | | | | | | | Signed-off-by: Daniel Nephin <dnephin@gmail.com>
* | Format environment variables to match docker-cli.Daniel Nephin2016-02-231-4/+9
|/ | | | Signed-off-by: Daniel Nephin <dnephin@gmail.com>
* Fix TLS regressionsAanand Prasad2016-02-231-1/+1
| | | | | | | | | - Set `verify` to the CA cert path if one has been specified, rather than `True` - Don't set `assert_fingerprint` Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
* Never exclude Dockerfile from the build context.926-ignored_dockerfilesJoffrey F2016-02-091-1/+7
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Re-write kwargs_from_env to handle TLS options betterMike Dougherty2016-02-041-11/+30
| | | | | | | | 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>
* Add support for shm_size.Spencer Rinehart2016-02-041-1/+8
| | | | | | | --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>
* Update outdated error message914_hostconfig_startJoffrey F2016-01-291-1/+1
| | | | Signed-off-by: Joffrey F <joffrey@docker.com>
* Support unspecified protocol in base_url when using TLS894-docker_host_envJoffrey F2016-01-281-2/+2
| | | | | | (assume HTTPS) Signed-off-by: Joffrey F <joffrey@docker.com>
* Support links when creating containers or connecting to networksAanand Prasad2016-01-201-7/+14
| | | | Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>