Releases: docker/docker-py
Releases · docker/docker-py
3.2.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug with builds not properly identifying Dockerfile paths relative
to the build context - Fixed an issue where builds would raise a
ValueError
when attempting to
build with a Dockerfile on a different Windows drive.
3.2.0
List of PRs / issues for this release
Features
- Generators returned by
attach()
,logs()
andevents()
now have a
cancel()
method to let consumers stop the iteration client-side. build()
methods can now handle Dockerfiles supplied outside of the
build context.- Added
sparse
argument toDockerClient.containers.list()
- Added
isolation
parameter tobuild()
methods. - Added
close()
method toDockerClient
- Added
APIClient.inspect_distribution()
method and
DockerClient.images.get_registry_data()
- The latter returns an instance of the new
RegistryData
class
- The latter returns an instance of the new
3.1.4
List of PRs / issues for this release
Bugfixes
- Fixed a bug where build contexts containing directory symlinks would produce
invalid tar archives
3.1.3
List of PRs / issues for this release
Bugfixes
- Fixed a bug that led to a Dockerfile not being included in the build context
in some situations when the Dockerfile's path was prefixed with./
- Regenerated invalid wheel package
3.1.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug that caused costly DNS lookups on Mac OSX when connecting to the
engine through UNIX socket - Fixed a bug that caused
.dockerignore
comments to be read as exclusion
patterns
3.1.0
List of PRs / issues for this release
Features
- Added support for
device_cgroup_rules
in host config - Added support for
generic_resources
when creating aResources
object. - Added support for a configurable
chunk_size
parameter inexport
,
get_archive
andget_image
(Image.save
) - Added a
force_update
method to theService
class. - In
Service.update
, when theforce_update
parameter is set toTrue
,
the currentforce_update
counter is incremented by one in the update
request.
Bugfixes
- Fixed a bug where authentication through
login()
was being ignored if the
SDK was configured to use a credential store. - Fixed a bug where download methods would use an absurdly small chunk size,
leading to slow data retrieval - Fixed a bug where using
DockerClient.images.pull
to pull an image by digest
would lead to an exception being raised. .dockerignore
rules should now be respected as defined by the spec,
including respect for last-line precedence and proper handling of absolute
paths- The
pass
credential store is now properly supported.
3.0.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug where
APIClient.login
didn't populate the_auth_configs
dictionary properly, causing subsequentpull
andpush
operations to fail - Fixed a bug where some build context files were incorrectly recognized as
being inaccessible. - Fixed a bug where files with a negative mtime value would
cause errors when included in a build context
3.0.0
List of PRs / issues for this release
Breaking changes
- Support for API version < 1.21 has been removed.
- The following methods have been removed:
APIClient.copy
has been removed. Users should useAPIClient.get_archive
instead.APIClient.insert
has been removed. Users may useAPIClient.put_archive
combined withAPIClient.commit
to replicate the method's behavior.utils.ping_registry
andutils.ping
have been removed.
- The following parameters have been removed:
stream
inAPIClient.build
cpu_shares
,cpuset
,dns
,mem_limit
,memswap_limit
,
volume_driver
,volumes_from
inAPIClient.create_container
. These are
all replaced by their equivalent increate_host_config
insecure_registry
inAPIClient.login
,APIClient.pull
,
APIClient.push
,DockerClient.images.push
andDockerClient.images.pull
viz
inAPIClient.images
- The following parameters have been renamed:
endpoint_config
inAPIClient.create_service
and
APIClient.update_service
is nowendpoint_spec
name
inDockerClient.images.pull
is nowrepository
- The return value for the following methods has changed:
APIClient.wait
andContainer.wait
now return adict
representing
the API's response instead of returning the status code directly.DockerClient.images.load
now returns a list ofImage
objects that have
for the images that were loaded, instead of a log stream.Container.exec_run
now returns a tuple of (exit_code, output) instead of
just the output.DockerClient.images.build
now returns a tuple of (image, build_logs)
instead of just the image object.APIClient.export
,APIClient.get_archive
andAPIClient.get_image
now
return generators streaming the raw binary data from the server's response.- When no tag is provided,
DockerClient.images.pull
now returns a list of
Image
s associated to the pulled repository instead of just thelatest
image.
Features
- The Docker Python SDK is now officially supported on Python 3.6
- Added
scale
method to theService
model ; this method is a shorthand
that callsupdate_service
with the required number of replicas - Added support for the
platform
parameter inAPIClient.build
,
DockerClient.images.build
,APIClient.pull
andDockerClient.images.pull
- Added support for the
until
parameter inAPIClient.logs
and
Container.logs
- Added support for the
workdir
argument inAPIClient.exec_create
and
Container.exec_run
- Added support for the
condition
argument inAPIClient.wait
and
Container.wait
- Users can now specify a publish mode for ports in
EndpointSpec
using
the{published_port: (target_port, protocol, publish_mode)}
syntax. - Added support for the
isolation
parameter inContainerSpec
,
DockerClient.services.create
andService.update
APIClient.attach_socket
,APIClient.exec_create
now allow specifying a
detach_keys
combination. If unspecified, the value from theconfig.json
file will be used- TLS connections now default to using the TLSv1.2 protocol when available
Bugfixes
- Fixed a bug where whitespace-only lines in
.dockerignore
would break builds
on Windows - Fixed a bug where broken symlinks inside a build context would cause the
build to fail - Fixed a bug where specifying volumes with Windows drives would cause
incorrect parsing inDockerClient.containers.run
- Fixed a bug where the
networks
data provided tocreate_service
and
update_service
would be sent incorrectly to the Engine with API < 1.25 - Pulling all tags from a repository with no
latest
tag using the
DockerClient
will no longer raise aNotFound
exception
2.7.0
List of PRs / issues for this release
Features
- Added
unlock_swarm
andget_unlock_key
methods to theAPIClient
.- Added
unlock
andget_unlock_key
toDockerClient.swarm
.
- Added
- Added a
greedy
parameter toDockerClient.networks.list
, yielding
additional details about the listed networks. - Added
cpu_rt_runtime
andcpu_rt_period
as parameters to
APIClient.create_host_config
andDockerClient.containers.run
. - Added the
order
argument toUpdateConfig
. - Added
fetch_current_spec
toAPIClient.update_service
andService.update
that will retrieve the current configuration of the service and merge it with
the provided parameters to determine the new configuration.
Bugfixes
- Fixed a bug where the
build
method tried to include inaccessible files
in the context, leading to obscure errors during the build phase
(inaccessible files inside the context now raise anIOError
instead). - Fixed a bug where the
build
method would try to read from FIFOs present
inside the build context, causing it to hang. APIClient.stop
will no longer override thestop_timeout
value present
in the container's configuration.- Fixed a bug preventing removal of networks with names containing a space.
- Fixed a bug where
DockerClient.containers.run
would crash if the
auto_remove
parameter was set toTrue
. - Changed the default value of
listen_addr
injoin_swarm
to match the
one ininit_swarm
. - Fixed a bug where handling HTTP errors with no body would cause an unexpected
exception to be thrown while generating anAPIError
object.
2.6.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug on Python 3 installations preventing the use of the
attach
and
exec_run
methods.