Releases: docker/docker-py
Releases · docker/docker-py
2.6.0
List of PRs / issues for this release
Features
- Added support for
mounts
inAPIClient.create_host_config
and
DockerClient.containers.run
- Added support for
consistency
,tmpfs_size
andtmpfs_mode
when
creating mount objects. Mount
objects now support thetmpfs
andnpipe
types.- Added support for
extra_hosts
in thebuild
methods. - Added support for the configs API:
- In
APIClient
:create_config
,inspect_config
,remove_config
,
configs
- In
DockerClient
:configs.create
,configs.get
,configs.list
and
theConfig
model. - Added
configs
parameter toContainerSpec
. Each item in theconfigs
list must be adocker.types.ConfigReference
instance.
- In
- Added support for the following parameters when creating a
ContainerSpec
object:groups
,open_stdin
,read_only
,stop_signal
,helathcheck
,
hosts
,ns_config
,configs
,privileges
. - Added the following configuration classes to
docker.types
:
ConfigReference
,DNSConfig
,Privileges
,SwarmExternalCA
. - Added support for
driver
inAPIClient.create_secret
and
DockerClient.secrets.create
. - Added support for
scope
inAPIClient.inspect_network
and
APIClient.create_network
, and theirDockerClient
equivalent. - Added support for the following parameters to
create_swarm_spec
:
external_cas
,labels
,signing_ca_cert
,signing_ca_key
,
ca_force_rotate
,autolock_managers
,log_driver
. These additions
also apply toDockerClient.swarm.init
. - Added support for
insert_defaults
inAPIClient.inspect_service
and
DockerClient.services.get
.
Bugfixes
- Fixed a bug where reading a 0-length frame in log streams would incorrectly
interrupt streaming. - Fixed a bug where the
id
member onSwarm
objects wasn't being populated. - Fixed a bug that would cause some data at the beginning of an upgraded
connection stream (attach
,exec_run
) to disappear.
2.5.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug where patterns ending with
**
in.dockerignore
would
raise an exception - Fixed a bug where using
attach
with thestream
argument set toFalse
would raise an exception
2.5.0
List of PRs / issues for this release
Features
- Added support for the
squash
parameter inAPIClient.build
and
DockerClient.images.build
. - When using API version 1.23 or above,
load_image
will now return a
generator of progress as JSONdict
s. remove_image
now returns the content of the API's response.
Bugfixes
- Fixed an issue where the
auto_remove
parameter in
DockerClient.containers.run
was not taken into account. - Fixed a bug where
.dockerignore
patterns starting with a slash
were ignored. - Fixed an issue with the handling of
**
patterns in.dockerignore
- Fixed a bug where building
FROM
a private Docker Hub image when not
using a cred store would fail. - Fixed a bug where calling
create_service
orupdate_service
with
task_template
as adict
would raise an exception. - Fixed the handling of TTY-enabled containers in
attach
andexec_run
. DockerClient.containers.run
will no longer attempt to stream logs if the
log driver doesn't support the operation.
Miscellaneous
- Added extra requirements for better TLS support on some platforms.
These can be installed or required through thedocker[tls]
notation.
2.4.2
List of issues / PRs for this release
Bugfixes
- Fixed a bug where the
split_port
utility would raise an exception when
passed a non-string argument.
2.4.0
List of PRs / issues for this release
Features
- Added support for the
target
andnetwork_mode
parameters in
APIClient.build
andDockerClient.images.build
. - Added support for the
runtime
parameter inAPIClient.create_container
andDockerClient.containers.run
. - Added support for the
ingress
parameter inAPIClient.create_network
and
DockerClient.networks.create
. - Added support for
placement
configuration indocker.types.TaskTemplate
. - Added support for
tty
configuration indocker.types.ContainerSpec
. - Added support for
start_period
configuration indocker.types.Healthcheck
. - The
credHelpers
section in Docker's configuration file is now recognized. - Port specifications including IPv6 endpoints are now supported.
Bugfixes
- Fixed a bug where instantiating a
DockerClient
usingdocker.from_env
wouldn't correctly set the default timeout value. - Fixed a bug where
DockerClient.secrets
was not accessible as a property. - Fixed a bug where
DockerClient.build
would sometimes return the wrong
image. - Fixed a bug where values for
HostConfig.nano_cpus
exceeding 2^32 would
raise a type error. Image.tag
now properly returnsTrue
when the operation is successful.APIClient.logs
andContainer.logs
now raise an exception if thesince
argument uses an unsupported type instead of ignoring the value.- Fixed a bug where some methods would raise a
NullResource
exception when
the resource ID was provided using a keyword argument.
Miscellaneous
APIClient
instances can now be pickled.
2.3.0
2.3.0
List of PRs / issues for this release
Features
- Added support for the following
HostConfig
parameters:volume_driver
,
cpu_count
,cpu_percent
,nano_cpus
,cpuset_mems
. - Added support for
verbose
parameter inAPIClient.inspect_network
and
DockerClient.networks.get
. - Added support for the
environment
parameter inAPIClient.exec_create
andContainer.exec_run
- Added
reload_config
method toAPIClient
, that lets the user reload
theconfig.json
data from disk. - Added
labels
property to theImage
andContainer
classes. - Added
image
property to theContainer
class.
Bugfixes
- Fixed a bug where setting
replicas
to zero inServiceMode
would not
register as a valid entry. - Fixed a bug where
DockerClient.images.build
would report a failure after
a successful build if atag
was set. - Fixed an issue where
DockerClient.images.pull
would fail to return the
corresponding image object if atag
was set. - Fixed a bug where a list of
mounts
provided toAPIClient.create_service
would sometimes be parsed incorrectly. - Fixed a bug where calling
Network.containers
would crash when no containers
were associated with the network. - Fixed an issue where
Network.connect
andNetwork.disconnect
would not
accept some of the documented parameters. - Fixed a bug where the
cpuset_cpus
parameter would not be properly set in
APIClient.create_host_config
.
Miscellaneous
- The invalid
networks
argument inDockerClient.containers.run
has been
replaced with a (working) singularnetwork
argument.
2.2.1
2.2.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug where the
status_code
attribute ofAPIError
exceptions would
not reflect the expected value. - Fixed an issue where the
events
method would time out unexpectedly if no
data was sent by the engine for a given amount of time.
2.2.0
2.2.0
List of PRs / issues for this release
Features
- Default API version has been bumped to
1.26
(Engine 1.13.1+) - Upgrade plugin:
- Added the
upgrade_plugin
method to theAPIClient
class - Added the
upgrade
method to thePlugin
class
- Added the
- Service logs:
- Added the
service_logs
method to theAPIClient
class - Added the
logs
method to theService
class
- Added the
- Added the
df
method toAPIClient
andDockerClient
- Added support for
init
andinit_path
parameters inHostConfig
andDockerClient.containers.run
- Added support for
hostname
parameter inContainerSpec
and
DockerClient.service.create
- Added support for port range to single port in port mappings
(e.g.8000-8010:80
)
Bugfixes
- Fixed a bug where a missing container port in a port mapping would raise
an unexpectedTypeError
- Fixed a bug where the
events
method inAPIClient
andDockerClient
would not respect custom headers set inconfig.json
2.1.0
2.1.0
List of PRs / issues for this release
Features
- Added the following pruning methods:
- In
APIClient
:prune_containers
,prune_images
,prune_networks
,
prune_volumes
- In
DockerClient
:containers.prune
,images.prune
,networks.prune
,
volumes.prune
- In
- Added support for the plugins API:
- In
APIClient
:configure_plugin
,create_plugin
,disable_plugin
,
enable_plugin
,inspect_plugin
,pull_plugin
,plugins
,
plugin_privileges
,push_plugin
,remove_plugin
- In
DockerClient
:plugins.create
,plugins.get
,plugins.install
,
plugins.list
, and thePlugin
model.
- In
- Added support for the secrets API:
- In
APIClient
:create_secret
,inspect_secret
,remove_secret
,
secrets
- In
DockerClient
:secret.create
,secret.get
,secret.list
and
theSecret
model. - Added
secrets
parameter toContainerSpec
. Each item in thesecrets
list must be adocker.types.SecretReference
instance.
- In
- Added support for
cache_from
inAPIClient.build
and
DockerClient.images.build
. - Added support for
auto_remove
andstorage_opt
in
APIClient.create_host_config
andDockerClient.containers.run
- Added support for
stop_timeout
inAPIClient.create_container
and
DockerClient.containers.run
- Added support for the
force
parameter inAPIClient.remove_volume
and
Volume.remove
- Added support for
max_failure_ratio
andmonitor
inUpdateConfig
- Added support for
force_update
inTaskTemplate
- Made
name
parameter optional inAPIClient.create_volume
and
DockerClient.volumes.create
Bugfixes
- Fixed a bug where building from a directory containing socket-type files
would raise an unexpectedAttributeError
. - Fixed an issue that was preventing the
DockerClient.swarm.init
method to
take into account arguments passed to it. Image.tag
now correctly returns a boolean value upon completion.- Fixed several issues related to passing
volumes
in
DockerClient.containers.run
- Fixed an issue where
DockerClient.image.build
wouldn't return anImage
object even when the build was successful
2.0.2
2.0.2
List of PRs / issues for this release
Bugfixes
- Installation of the package now fails if the
docker-py
package is
installed in order to prevent obscure naming conflicts when both
packages co-exist. - Added missing
filters
parameter toAPIClient.networks
. - Resource objects generated by the
DockerClient
are now hashable. - Fixed a bug where retrieving untagged images using
DockerClient
would raise aTypeError
exception. mode
parameter increate_service
is now properly converted to
a valid data type for the Engine API. UseServiceMode
for advanced
configurations.- Fixed a bug where the decoded
APIClient.events
stream would sometimes raise
an exception when a container is stopped or restarted.