| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
| |
fix: api - container.stats infinite blocking on stream mode
Includes additional test for no streaming
Signed-off-by: Bharath Vignesh J K <52282402+RazCrimson@users.noreply.github.com>
|
| |
|
| |
Signed-off-by: John Yang <john.yang20@berkeley.edu>
|
| |
|
| |
Signed-off-by: Aarni Koskela <akx@iki.fi>
|
| |
|
| |
Signed-off-by: Lorin Bucher <lorin@lbtec.dev>
|
| |
|
| |
Signed-off-by: Andy Roxby <107427605+aroxby-wayscript@users.noreply.github.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Requests with stream=True MUST be closed or else the connection will
never be returned to the connection pool. Both ContainerApiMixin.attach
and ExecApiMixin.exec_start were leaking in the stream=False case.
exec_start was modified to follow attach for the stream=True case as
that allows the caller to close the stream when done (untested).
Tested with:
# Test exec_run (stream=False) - observe one less leak
make integration-test-py3 file=models_containers_test.py' -k test_exec_run_success -vs -W error::ResourceWarning'
# Test exec_start (stream=True, fully reads from CancellableStream)
make integration-test-py3 file=api_exec_test.py' -k test_execute_command -vs -W error::ResourceWarning'
After this change, one resource leak is removed, the remaining resource
leaks occur because none of the tests call client.close().
Fixes https://github.com/docker/docker-py/issues/1293
(Regression from https://github.com/docker/docker-py/pull/1130)
Signed-off-by: Peter Wu <pwu@cloudflare.com>
Co-authored-by: Milas Bowman <milas.bowman@docker.com>
|
| |
|
|
|
|
|
|
| |
Add support for floats to docker logs params `since` / `until` since the
Docker Engine APIs support it.
This allows using fractional seconds for greater precision.
Signed-off-by: Archi Moebius <poerhiz@gmail.com>
|
| |
|
|
|
|
| |
Adds support for setting the UDP port used for VXLAN traffic between
swarm nodes
Signed-off-by: Chris Hand <dexteradeus@users.noreply.github.com>
|
| |\ |
|
| | |
| |
| | |
Signed-off-by: Saurav Maheshkar <sauravvmaheshkar@gmail.com>
|
| | |
| |
| | |
Signed-off-by: till <till@php.net>
|
| | |
| |
| |
| |
| |
| |
| | |
Add platform parameter for container creation/run
Signed-off-by: Felix Fontein <felix@fontein.de>
Signed-off-by: Milas Bowman <milas.bowman@docker.com>
Co-authored-by: Milas Bowman <milas.bowman@docker.com>
|
| | |\
| | |
| | | |
ci: add flake8 job
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | | |
Since flake8 wasn't actually being run in CI, we'd accumulated some
violations.
Signed-off-by: Milas Bowman <milas.bowman@docker.com>
|
| | |/
| |
| |
| |
| | |
We want "The above exception was the direct cause of the following exception:" instead of "During handling of the above exception, another exception occurred:"
Signed-off-by: Maor Kleinberger <kmaork@gmail.com>
|
| | |\
| | |
| | | |
Fix volumes low-level documentation examples
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | | |
I realize that low-level documentation has outdated examples, so I
created issue #2800 to fix that
Signed-off-by: Felipe Ruhland <felipe.ruhland@gmail.com>
|
| | |\ \
| | | |
| | | | |
Fix swarm low-level documentation examples
|
| | | |/
| | |
| | |
| | |
| | |
| | |
| | | |
I realize that low-level documentation has outdated examples, so I
created issue #2800 to fix that
Signed-off-by: Felipe Ruhland <felipe.ruhland@gmail.com>
|
| | |\ \
| | | |
| | | | |
Fix network low-level documentation examples
|
| | | |/
| | |
| | |
| | |
| | |
| | |
| | | |
I realize that low-level documentation has outdated examples, so I
created issue #2800 to fix that
Signed-off-by: Felipe Ruhland <felipe.ruhland@gmail.com>
|
| | |\ \ |
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Fixes #931
Signed-off-by: Segev Finer <segev208@gmail.com>
|
| | | |/
| | |
| | |
| | | |
Signed-off-by: Anthony Sottile <asottile@umich.edu>
|
| | |/
| |
| |
| | |
Signed-off-by: Sebastiano Mariani <smariani@vmware.com>
|
| | |\
| | |
| | | |
Add limit parameter to image search endpoint
|
| | | |
| | |
| | |
| | | |
Signed-off-by: Felipe Ruhland <felipe.ruhland@gmail.com>
|
| | |\ \
| | | |
| | | | |
Fix images low-level documentation examples
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
I realize that the documentation of low-level `images` was outdated when
answering issue #2798
The issue can reproduce it with a simple test:
```py
In [1]: import docker
In [2]: client = docker.from_env()
In [3]: client.pull
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
<ipython-input-3-d0931943ca5d> in <module>
----> 1 client.pull
~/docker-py/docker/client.py in __getattr__(self, name)
219 "object APIClient. See the low-level API section of the "
220 "documentation for more details.")
--> 221 raise AttributeError(' '.join(s))
222
223
AttributeError: 'DockerClient' object has no attribute 'pull' In Docker SDK for Python 2.0, this method is now on the object APIClient. See the low-level API section of the documentation for more details.
In [4]: client.push
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
<ipython-input-4-f7d5b860a184> in <module>
----> 1 client.push
~/docker-py/docker/client.py in __getattr__(self, name)
219 "object APIClient. See the low-level API section of the "
220 "documentation for more details.")
--> 221 raise AttributeError(' '.join(s))
222
223
AttributeError: 'DockerClient' object has no attribute 'push' In Docker SDK for Python 2.0, this method is now on the object APIClient. See the low-level API section of the documentation for more details.
In [5]: client.tag
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
<ipython-input-5-043bdfd088ca> in <module>
----> 1 client.tag
~/docker-py/docker/client.py in __getattr__(self, name)
219 "object APIClient. See the low-level API section of the "
220 "documentation for more details.")
--> 221 raise AttributeError(' '.join(s))
222
223
AttributeError: 'DockerClient' object has no attribute 'tag' In Docker SDK for Python 2.0, this method is now on the object APIClient. See the low-level API section of the documentation for more details.
In [6]: client.get_image
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
<ipython-input-6-477c12713276> in <module>
----> 1 client.get_image
~/docker-py/docker/client.py in __getattr__(self, name)
219 "object APIClient. See the low-level API section of the "
220 "documentation for more details.")
--> 221 raise AttributeError(' '.join(s))
222
223
AttributeError: 'DockerClient' object has no attribute 'get_image' In Docker SDK for Python 2.0, this method is now on the object APIClient. See the low-level API section of the documentation for more details.
In [7]: client.api.get_image
Out[7]: <bound method ImageApiMixin.get_image of <docker.api.client.APIClient object at 0x7fad6a2037c0>>
In [8]: client.api.tag
Out[8]: <bound method ImageApiMixin.tag of <docker.api.client.APIClient object at 0x7fad6a2037c0>>
In [9]: client.api.pull
Out[9]: <bound method ImageApiMixin.pull of <docker.api.client.APIClient object at 0x7fad6a2037c0>>
In [10]: client.api.push
Out[10]: <bound method ImageApiMixin.push of <docker.api.client.APIClient object at 0x7fad6a2037c0>>
```
Signed-off-by: Felipe Ruhland <felipe.ruhland@gmail.com>
|
| | |/ /
| | |
| | |
| | |
| | |
| | |
| | | |
I realize that low-level documentation has outdated examples, so I
created issue #2800 to fix that
Signed-off-by: Felipe Ruhland <felipe.ruhland@gmail.com>
|
| | |/
| |
| |
| | |
Signed-off-by: Ulysses Souza <ulyssessouza@gmail.com>
|
| | |
| |
| |
| | |
Signed-off-by: Vlad Romanenko <vlad.romanenko@hotmail.com>
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The "filter" argument was deprecated in docker 1.13 (API version 1.25),
and removed from API v1.41 and up. See https://github.com/docker/cli/blob/v20.10.0-rc1/docs/deprecated.md#filter-param-for-imagesjson-endpoint
This patch applies the name as "reference" filter, instead of "filter" for API
1.25 and up.
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
|
| | |\
| | |
| | | |
raise an error for binding specific ports in 'host' mode of network
|
| | | |
| | |
| | |
| | | |
Signed-off-by: Daeseok Youn <daeseok.youn@navercorp.com>
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The binding ports are ignored where the network mode is 'host'.
It could be a problem in case of using these options together on
Mac or Windows OS. Because the limitation that could not use
the 'host' in network_mode on Mac and Windows. When 'host' mode
is set on network_mode, the specific ports in 'ports' are ignored
so the network is not able to be accessed through defined ports
by developer.
Signed-off-by: Daeseok Youn <daeseok.youn@navercorp.com>
|
| | |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* Add max_pool_size parameter
Signed-off-by: Mariano Scazzariello <marianoscazzariello@gmail.com>
* Add client version to tests
Signed-off-by: Mariano Scazzariello <marianoscazzariello@gmail.com>
* Fix parameter position
Signed-off-by: Mariano Scazzariello <marianoscazzariello@gmail.com>
|
| | |\
| | |
| | | |
Set image default tag on pull
|
| | | |
| | |
| | |
| | | |
Signed-off-by: aiordache <anca.iordache@docker.com>
|
| | | |
| | |
| | |
| | | |
Signed-off-by: aiordache <anca.iordache@docker.com>
|
| | |/
| |
| |
| | |
Signed-off-by: aiordache <anca.iordache@docker.com>
|
| | |
| |
| |
| | |
Signed-off-by: aiordache <anca.iordache@docker.com>
|
| | |
| |
| |
| | |
Signed-off-by: aiordache <anca.iordache@docker.com>
|
| | |
| |
| |
| |
| |
| |
| |
| | |
* Fix memory conversion to bytes
Co-authored-by: Ulysses Souza <ulysses.souza@gmail.com>
Signed-off-by: aiordache <anca.iordache@docker.com>
|
| | |\
| | |
| | | |
Disable compression by default when using container:get_archive method
|
| | | |
| | |
| | |
| | | |
Signed-off-by: Niklas Saari <niklas.saari@tutanota.com>
|
| | | |
| | |
| | | |
Signed-off-by: Ville Skyttä <ville.skytta@iki.fi>
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* Add DeviceRequest type
Signed-off-by: Erwan Rouchet <rouchet@teklia.com>
* Add device_requests kwarg in host config
Signed-off-by: Erwan Rouchet <rouchet@teklia.com>
* Add unit test for device requests
Signed-off-by: Erwan Rouchet <rouchet@teklia.com>
* Fix unit test
Signed-off-by: Erwan Rouchet <rouchet@teklia.com>
* Use parentheses for multiline import
Signed-off-by: Erwan Rouchet <rouchet@teklia.com>
* Create 1.40 client for device-requests test
Signed-off-by: Laurie O <laurie_opperman@hotmail.com>
Co-authored-by: Laurie O <laurie_opperman@hotmail.com>
Co-authored-by: Bastien Abadie <abadie@teklia.com>
|
| | |/
| |
| |
| |
| |
| |
| | |
Docker API 1.32 added support for providing options to a network driver
via EndpointConfig when connecting a container to a network.
Signed-off-by: Mike Haboustak <haboustak@gmail.com>
|
| | |
| |
| |
| | |
Signed-off-by: Yuval Goldberg <yuvigoldi@hotmail.com>
|