summaryrefslogtreecommitdiff
path: root/docker/unixconn/unixconn.py
Commit message (Collapse)AuthorAgeFilesLines
* Fix Unix adapter bug with newer versions of requests811-unix-adapterJoffrey F2015-10-191-3/+11
| | | | | | | | | The select_proxy utility in requests errors out when the provided URL doesn't have a hostname, like is the case when using a UNIX socket. Since proxies are an irrelevant notion in the case of UNIX sockets anyway, we simply return the path URL directly. Signed-off-by: Joffrey F <joffrey@docker.com>
* Merge branch 'sam/import-improvements' of ↵Joffrey F2015-04-221-18/+14
|\ | | | | | | | | | | | | | | | | https://github.com/ssssam/docker-py into ssssam-sam/import-improvements Conflicts: docker/client.py docker/unixconn/unixconn.py tests/integration_test.py
| * Rework Unix connection code so that 'chunked' transfers workSam Thursfield2015-01-051-16/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows streaming a system to the 'import' command, rather than having to read the whole thing into memory before sending it. Previously both the UnixAdapter and the docker.Client objects would track the 'base URL' of the Docker daemon (socket path in the case of local Unix-domain socket connections). The Client object would construct URLs which contained the path to the socket with the path of the Docker API call appended. The UnixHTTPConnection instance would then remove the known socket path from the URL. This relied on all calls going through the HTTPConnection.request() function, where the URL could be rewritten. In the case of 'chunked' HTTP POST requests this doesn't happen, so such calls would request a path still including the socket path and would receive a 404 error. The client now constructs URLs containing just the path of the desired API endpoint, and expects the Unix socket transport to know the path to the Docker daemon's socket.
* | Added rename methodJoffrey F2015-02-101-2/+2
| |
* | urllib3/requests issuesJoffrey F2015-01-091-5/+5
| |
* | Prioritize system-installed urllib3 over requests vendored urllib3.Joffrey F2015-01-081-10/+7
|/
* Clear the UNIX connection sockets properlyAlexey Kotlyarov2014-09-221-1/+21
|
* Fixes for flake8Evgeniy L2014-03-281-1/+1
| | | | | | Next rules were broken * E265 block comment should start with '# ' * E713 test for membership should be 'not in'
* Support requests >=2.1.0Darren Shepherd2014-01-261-1/+1
| | | | | | | | | | | | | | | | | Starting with requests 2.1.0 non-HTTP scheme URLs are not parsed anymore. The net effect of this is that when using the unix socket in docker-py no query string params are passed in the URL. This change makes docker-py internally use the scheme http+unix to indicate to requests that this is still a HTTP URL and should be parsed. Users of docker-py can still specify 'unix:' as the base_url. The following forms of base_url are accepted. http+unix://var/run/docker.sock unix://var/run/docker.sock unix:///var/run/docker.sock http://hostname tcp://hostname
* Merge branch 'timeout-support' of github.com:mpetazzoni/docker-py into ↵shin-2013-11-151-8/+14
|\ | | | | | | | | | | | | | | | | mpetazzoni-timeout-support Conflicts: docker/client.py tests/integration_test.py tests/test.py
| * Allow for configurable timeout on all client requestsMaxime Petazzoni2013-11-081-9/+13
|/ | | | Signed-off-by: Maxime Petazzoni <max@signalfuse.com>
* Added support for unix:/// protocol (default for docker CLI)shin-2013-10-161-1/+1
|
* Refactoring, Python 3 compatibility, Tests working with python 3, cleaned up ↵shin-2013-10-151-0/+65
imports.