67 KiB
Change log
4.1.0
List of PRs / issues for this release
Bugfixes
- Correct
INDEX_URLlogic in build.py _set_auth_headers - Fix for empty auth keys in config.json
Features
- Add
NetworkAttachmentConfigfor service create/update
Miscellaneous
- Bump pytest to 4.3.1
- Adjust
--platformtests for changes in docker engine - Update credentials-helpers to v0.6.3
4.0.2
List of PRs / issues for this release
Bugfixes
- Unified the way
HealthCheckis created/configured
Miscellaneous
- Bumped version of websocket-client
4.0.1
List of PRs / issues for this release
Bugfixes
- Fixed an obsolete import in the
credentialssubpackage that caused import errors in Python 3.7
Miscellaneous
- Docs building has been repaired
4.0.0
List of PRs / issues for this release
Breaking changes
- Support for Python 3.3 and Python 3.4 has been dropped
APIClient.update_service,APIClient.init_swarm, andDockerClient.swarm.initnow return adictfrom the API's response body- In
APIClient.buildandDockerClient.images.build, theuse_config_proxyparameter now defaults to True init_pathis no longer a valid parameter forHostConfig
Features
- It is now possible to provide
SCTPports for port mappings ContainerSpecs now support theinitparameterDockerClient.swarm.initandAPIClient.init_swarmnow support thedata_path_addrparameterAPIClient.update_swarmandDockerClient.swarm.updatenow support therotate_manager_unlock_keyparameterAPIClient.update_servicereturns the API's response body as adictAPIClient.init_swarm, andDockerClient.swarm.initnow return the API's response body as adict
Bugfixes
- Fixed
PlacementPreferenceinstances to produce a valid API type - Fixed a bug where not setting a value for
buildargsinbuildcould cause the library to attempt accessing attributes of aNonevalue - Fixed a bug where setting the
volume_driverparameter inDockerClient.containers.createwould result in an error APIClient.inspect_distributionnow correctly sets the authentication headers on the request, allowing it to be used with private repositories This change also applies toDockerClient.get_registry_data
3.7.2
List of PRs / issues for this release
Bugfixes
- Fix base_url to keep TCP protocol on utils.py by letting the responsability of changing the
protocol to
parse_hostafterwards, lettingbase_urlwith the original value. - XFAIL test_attach_stream_and_cancel on TLS
3.7.1
List of PRs / issues for this release
Bugfixes
- Set a different default number (which is now 9) for SSH pools
- Adds a BaseHTTPAdapter with a close method to ensure that the pools is clean on close()
- Makes SSHHTTPAdapter reopen a closed connection when needed like the others
3.7.0
List of PRs / issues for this release
Features
- Added support for multiplexed streams (for
attachandexec_start). Learn more at https://docker-py.readthedocs.io/en/stable/user_guides/multiplex.html - Added the
use_config_proxyparameter to the following methods:APIClient.build,APIClient.create_container,DockerClient.images.buildandDockerClient.containers.run(Falseby default). This parameter will becomeTrueby default in the 4.0.0 release. - Placement preferences for Swarm services are better validated on the client and documentation has been updated accordingly
Bugfixes
- Fixed a bug where credential stores weren't queried for relevant registry
credentials with certain variations of the
config.jsonfile. DockerClient.swarm.initnow returns a boolean value as advertised.
3.6.0
List of PRs / issues for this release
Features
- Added support for connecting to the Docker Engine over SSH. Additional
dependencies for this feature can be installed with
pip install "docker[ssh]" - Added support for the
namedparameter inImage.save, which may be used to ensure the resulting tarball retains the image's name on save.
Bugfixes
- Fixed a bug where builds on Windows with a context path using the
\\?\prefix would fail with some relative Dockerfile paths. - Fixed an issue where pulls made with the
DockerClientwould fail when setting thestreamparameter toTrue.
Miscellaneous
- The minimum requirement for the
requestsdependency has been bumped to 2.20.0
3.5.1
List of PRs / issues for this release
Miscellaneous
-
Bumped version of
pyOpenSSLinrequirements.txtandsetup.pyto prevent installation of a vulnerable version -
Docs fixes
3.5.0
List of PRs / issues for this release
Deprecation warning
- Support for Python 3.3 will be dropped in the 4.0.0 release
Features
- Updated dependencies to ensure support for Python 3.7 environments
- Added support for the
uts_modeparameter inHostConfig - The
UpdateConfigconstructor now allowsrollbackas a valid value forfailure_action - Added support for
rollback_configinAPIClient.create_service,APIClient.update_service,DockerClient.services.createandService.update.
Bugfixes
- Credential helpers are now properly leveraged by the
buildmethod - Fixed a bug that caused placement preferences to be ignored when provided
to
DockerClient.services.create - Fixed a bug that caused a
uservalue of0to be ignored inAPIClient.create_containerandDockerClient.containers.create
3.4.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug that caused auth values in config files written using one of the legacy formats to be ignored
- Fixed issues with handling of double-wildcard
**patterns in.dockerignorefiles
3.4.0
List of PRs / issues for this release
Features
- The
APIClientandDockerClientconstructors now accept acredstore_envparameter. When set, values in this dictionary are added to the environment when executing the credential store process.
Bugfixes
DockerClient.networks.prunenow properly returns the operation's result- Fixed a bug that caused custom Dockerfile paths in a subfolder of the build context to be invalidated, preventing these builds from working
- The
plugin_privilegesmethod can now be called for plugins requiring authentication to access - Fixed a bug that caused attempts to read a data stream over an unsecured TCP socket to crash on Windows clients
- Fixed a bug where using the
read_onlyparameter when creating a service using theDockerClientwas being ignored - Fixed an issue where
Service.scalewould not properly update the service's mode, causing the operation to fail silently
3.3.0
List of PRs / issues for this release
Features
- Added support for
prune_buildsinAPIClientandDockerClient.images - Added support for
ignore_removedparameter inDockerClient.containers.list
Bugfixes
- Fixed an issue that caused builds to fail when an in-context Dockerfile would be specified using its absolute path
- Installation with pip 10.0.0 and above no longer fails
- Connection timeout for
stopandrestartnow gets properly adjusted to allow for the operation to finish in the specified time - Improved docker credential store support on Windows
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
ValueErrorwhen 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 acancel()method to let consumers stop the iteration client-side. build()methods can now handle Dockerfiles supplied outside of the build context.- Added
sparseargument toDockerClient.containers.list() - Added
isolationparameter tobuild()methods. - Added
close()method toDockerClient - Added
APIClient.inspect_distribution()method andDockerClient.images.get_registry_data()- The latter returns an instance of the new
RegistryDataclass
- 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
Bugfixes
- Regenerated invalid wheel package
3.1.2
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
./
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
.dockerignorecomments to be read as exclusion patterns
3.1.0
List of PRs / issues for this release
Features
- Added support for
device_cgroup_rulesin host config - Added support for
generic_resourceswhen creating aResourcesobject. - Added support for a configurable
chunk_sizeparameter inexport,get_archiveandget_image(Image.save) - Added a
force_updatemethod to theServiceclass. - In
Service.update, when theforce_updateparameter is set toTrue, the currentforce_updatecounter 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.pullto pull an image by digest would lead to an exception being raised. .dockerignorerules should now be respected as defined by the spec, including respect for last-line precedence and proper handling of absolute paths- The
passcredential store is now properly supported.
3.0.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug where
APIClient.logindidn't populate the_auth_configsdictionary properly, causing subsequentpullandpushoperations 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.copyhas been removed. Users should useAPIClient.get_archiveinstead.APIClient.inserthas been removed. Users may useAPIClient.put_archivecombined withAPIClient.committo replicate the method's behavior.utils.ping_registryandutils.pinghave been removed.
- The following parameters have been removed:
streaminAPIClient.buildcpu_shares,cpuset,dns,mem_limit,memswap_limit,volume_driver,volumes_frominAPIClient.create_container. These are all replaced by their equivalent increate_host_configinsecure_registryinAPIClient.login,APIClient.pull,APIClient.push,DockerClient.images.pushandDockerClient.images.pullvizinAPIClient.images
- The following parameters have been renamed:
endpoint_configinAPIClient.create_serviceandAPIClient.update_serviceis nowendpoint_specnameinDockerClient.images.pullis nowrepository
- The return value for the following methods has changed:
APIClient.waitandContainer.waitnow return adictrepresenting the API's response instead of returning the status code directly.DockerClient.images.loadnow returns a list ofImageobjects that have for the images that were loaded, instead of a log stream.Container.exec_runnow returns a tuple of (exit_code, output) instead of just the output.DockerClient.images.buildnow returns a tuple of (image, build_logs) instead of just the image object.APIClient.export,APIClient.get_archiveandAPIClient.get_imagenow return generators streaming the raw binary data from the server's response.- When no tag is provided,
DockerClient.images.pullnow returns a list ofImages associated to the pulled repository instead of just thelatestimage.
Features
- The Docker Python SDK is now officially supported on Python 3.6
- Added
scalemethod to theServicemodel ; this method is a shorthand that callsupdate_servicewith the required number of replicas - Added support for the
platformparameter inAPIClient.build,DockerClient.images.build,APIClient.pullandDockerClient.images.pull - Added support for the
untilparameter inAPIClient.logsandContainer.logs - Added support for the
workdirargument inAPIClient.exec_createandContainer.exec_run - Added support for the
conditionargument inAPIClient.waitandContainer.wait - Users can now specify a publish mode for ports in
EndpointSpecusing the{published_port: (target_port, protocol, publish_mode)}syntax. - Added support for the
isolationparameter inContainerSpec,DockerClient.services.createandService.update APIClient.attach_socket,APIClient.exec_createnow allow specifying adetach_keyscombination. If unspecified, the value from theconfig.jsonfile will be used- TLS connections now default to using the TLSv1.2 protocol when available
Bugfixes
- Fixed a bug where whitespace-only lines in
.dockerignorewould 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 in
DockerClient.containers.run - Fixed a bug where the
networksdata provided tocreate_serviceandupdate_servicewould be sent incorrectly to the Engine with API < 1.25 - Pulling all tags from a repository with no
latesttag using theDockerClientwill no longer raise aNotFoundexception
2.7.0
List of PRs / issues for this release
Features
- Added
unlock_swarmandget_unlock_keymethods to theAPIClient.- Added
unlockandget_unlock_keytoDockerClient.swarm.
- Added
- Added a
greedyparameter toDockerClient.networks.list, yielding additional details about the listed networks. - Added
cpu_rt_runtimeandcpu_rt_periodas parameters toAPIClient.create_host_configandDockerClient.containers.run. - Added the
orderargument toUpdateConfig. - Added
fetch_current_spectoAPIClient.update_serviceandService.updatethat 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
buildmethod tried to include inaccessible files in the context, leading to obscure errors during the build phase (inaccessible files inside the context now raise anIOErrorinstead). - Fixed a bug where the
buildmethod would try to read from FIFOs present inside the build context, causing it to hang. APIClient.stopwill no longer override thestop_timeoutvalue present in the container's configuration.- Fixed a bug preventing removal of networks with names containing a space.
- Fixed a bug where
DockerClient.containers.runwould crash if theauto_removeparameter was set toTrue. - Changed the default value of
listen_addrinjoin_swarmto 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 an
APIErrorobject.
2.6.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug on Python 3 installations preventing the use of the
attachandexec_runmethods.
2.6.0
List of PRs / issues for this release
Features
- Added support for
mountsinAPIClient.create_host_configandDockerClient.containers.run - Added support for
consistency,tmpfs_sizeandtmpfs_modewhen creating mount objects. Mountobjects now support thetmpfsandnpipetypes.- Added support for
extra_hostsin thebuildmethods. - Added support for the configs API:
- In
APIClient:create_config,inspect_config,remove_config,configs - In
DockerClient:configs.create,configs.get,configs.listand theConfigmodel. - Added
configsparameter toContainerSpec. Each item in theconfigslist must be adocker.types.ConfigReferenceinstance.
- In
- Added support for the following parameters when creating a
ContainerSpecobject: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
driverinAPIClient.create_secretandDockerClient.secrets.create. - Added support for
scopeinAPIClient.inspect_networkandAPIClient.create_network, and theirDockerClientequivalent. - 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_defaultsinAPIClient.inspect_serviceandDockerClient.services.get.
Bugfixes
- Fixed a bug where reading a 0-length frame in log streams would incorrectly interrupt streaming.
- Fixed a bug where the
idmember onSwarmobjects 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.dockerignorewould raise an exception - Fixed a bug where using
attachwith thestreamargument set toFalsewould raise an exception
2.5.0
List of PRs / issues for this release
Features
- Added support for the
squashparameter inAPIClient.buildandDockerClient.images.build. - When using API version 1.23 or above,
load_imagewill now return a generator of progress as JSONdicts. remove_imagenow returns the content of the API's response.
Bugfixes
- Fixed an issue where the
auto_removeparameter inDockerClient.containers.runwas not taken into account. - Fixed a bug where
.dockerignorepatterns starting with a slash were ignored. - Fixed an issue with the handling of
**patterns in.dockerignore - Fixed a bug where building
FROMa private Docker Hub image when not using a cred store would fail. - Fixed a bug where calling
create_serviceorupdate_servicewithtask_templateas adictwould raise an exception. - Fixed the handling of TTY-enabled containers in
attachandexec_run. DockerClient.containers.runwill 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 the
docker[tls]notation.
2.4.2
List of PRs / issues for this release
Bugfixes
- Fixed a bug where the
split_portutility 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
targetandnetwork_modeparameters inAPIClient.buildandDockerClient.images.build. - Added support for the
runtimeparameter inAPIClient.create_containerandDockerClient.containers.run. - Added support for the
ingressparameter inAPIClient.create_networkandDockerClient.networks.create. - Added support for
placementconfiguration indocker.types.TaskTemplate. - Added support for
ttyconfiguration indocker.types.ContainerSpec. - Added support for
start_periodconfiguration indocker.types.Healthcheck. - The
credHelperssection in Docker's configuration file is now recognized. - Port specifications including IPv6 endpoints are now supported.
Bugfixes
- Fixed a bug where instantiating a
DockerClientusingdocker.from_envwouldn't correctly set the default timeout value. - Fixed a bug where
DockerClient.secretswas not accessible as a property. - Fixed a bug where
DockerClient.buildwould sometimes return the wrong image. - Fixed a bug where values for
HostConfig.nano_cpusexceeding 2^32 would raise a type error. Image.tagnow properly returnsTruewhen the operation is successful.APIClient.logsandContainer.logsnow raise an exception if thesinceargument uses an unsupported type instead of ignoring the value.- Fixed a bug where some methods would raise a
NullResourceexception when the resource ID was provided using a keyword argument.
Miscellaneous
APIClientinstances can now be pickled.
2.3.0
List of PRs / issues for this release
Features
- Added support for the following
HostConfigparameters:volume_driver,cpu_count,cpu_percent,nano_cpus,cpuset_mems. - Added support for
verboseparameter inAPIClient.inspect_networkandDockerClient.networks.get. - Added support for the
environmentparameter inAPIClient.exec_createandContainer.exec_run - Added
reload_configmethod toAPIClient, that lets the user reload theconfig.jsondata from disk. - Added
labelsproperty to theImageandContainerclasses. - Added
imageproperty to theContainerclass.
Bugfixes
- Fixed a bug where setting
replicasto zero inServiceModewould not register as a valid entry. - Fixed a bug where
DockerClient.images.buildwould report a failure after a successful build if atagwas set. - Fixed an issue where
DockerClient.images.pullwould fail to return the corresponding image object if atagwas set. - Fixed a bug where a list of
mountsprovided toAPIClient.create_servicewould sometimes be parsed incorrectly. - Fixed a bug where calling
Network.containerswould crash when no containers were associated with the network. - Fixed an issue where
Network.connectandNetwork.disconnectwould not accept some of the documented parameters. - Fixed a bug where the
cpuset_cpusparameter would not be properly set inAPIClient.create_host_config.
Miscellaneous
- The invalid
networksargument inDockerClient.containers.runhas been replaced with a (working) singularnetworkargument.
2.2.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug where the
status_codeattribute ofAPIErrorexceptions would not reflect the expected value. - Fixed an issue where the
eventsmethod would time out unexpectedly if no data was sent by the engine for a given amount of time.
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_pluginmethod to theAPIClientclass - Added the
upgrademethod to thePluginclass
- Added the
- Service logs:
- Added the
service_logsmethod to theAPIClientclass - Added the
logsmethod to theServiceclass
- Added the
- Added the
dfmethod toAPIClientandDockerClient - Added support for
initandinit_pathparameters inHostConfigandDockerClient.containers.run - Added support for
hostnameparameter inContainerSpecandDockerClient.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 unexpected
TypeError - Fixed a bug where the
eventsmethod inAPIClientandDockerClientwould not respect custom headers set inconfig.json
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 thePluginmodel.
- In
- Added support for the secrets API:
- In
APIClient:create_secret,inspect_secret,remove_secret,secrets - In
DockerClient:secret.create,secret.get,secret.listand theSecretmodel. - Added
secretsparameter toContainerSpec. Each item in thesecretslist must be adocker.types.SecretReferenceinstance.
- In
- Added support for
cache_frominAPIClient.buildandDockerClient.images.build. - Added support for
auto_removeandstorage_optinAPIClient.create_host_configandDockerClient.containers.run - Added support for
stop_timeoutinAPIClient.create_containerandDockerClient.containers.run - Added support for the
forceparameter inAPIClient.remove_volumeandVolume.remove - Added support for
max_failure_ratioandmonitorinUpdateConfig - Added support for
force_updateinTaskTemplate - Made
nameparameter optional inAPIClient.create_volumeandDockerClient.volumes.create
Bugfixes
- Fixed a bug where building from a directory containing socket-type files
would raise an unexpected
AttributeError. - Fixed an issue that was preventing the
DockerClient.swarm.initmethod to take into account arguments passed to it. Image.tagnow correctly returns a boolean value upon completion.- Fixed several issues related to passing
volumesinDockerClient.containers.run - Fixed an issue where
DockerClient.image.buildwouldn't return anImageobject even when the build was successful
2.0.2
List of PRs / issues for this release
Bugfixes
- Installation of the package now fails if the
docker-pypackage is installed in order to prevent obscure naming conflicts when both packages co-exist. - Added missing
filtersparameter toAPIClient.networks. - Resource objects generated by the
DockerClientare now hashable. - Fixed a bug where retrieving untagged images using
DockerClientwould raise aTypeErrorexception. modeparameter increate_serviceis now properly converted to a valid data type for the Engine API. UseServiceModefor advanced configurations.- Fixed a bug where the decoded
APIClient.eventsstream would sometimes raise an exception when a container is stopped or restarted.
2.0.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug where forward slashes in some .dockerignore patterns weren't being parsed correctly on Windows
- Fixed a bug where
Mount.parse_mount_stringwould never set the read_only parameter on the resultingMount. - Fixed a bug where
Mount.parse_mount_stringwould incorrectly mark host binds as being ofvolumetype.
2.0.0
List of PRs / issues for this release
Breaking changes
- Dropped support for Python 2.6
docker.Clienthas been renamed todocker.APIClientdocker.from_envnow creates aDockerClientinstance instead of anAPIClientinstance.- Removed HostConfig parameters from
APIClient.start - The minimum supported API version is now 1.21 (Engine version 1.9.0+)
- The name of the
pippackage is nowdocker(was:docker-py). New versions of this library will only be published asdockerfrom now on. docker.ssladapteris nowdocker.transport.ssladapter- The package structure has been flattened in certain cases, which may affect
import for
docker.authanddocker.utils.ports docker.utils.typeshas been moved todocker.typescreate_host_config,create_ipam_poolandcreate_ipam_confighave been removed fromdocker.utils. They have been replaced by the following classes indocker.types:HostConfig,IPAMPoolandIPAMCOnfig.
Features
- Added a high-level, user-focused API as
docker.DockerClient. See the README and documentation for more information. - Implemented
update_nodemethod inAPIClient. - Implemented
remove_nodemethod inAPIClient. - Added support for
restart_policyinupdate_container. - Added support for
labelsandshmsizeinbuild. - Added support for
attachableincreate_network - Added support for
healthcheckincreate_container. - Added support for
isolationinHostConfig. - Expanded support for
pid_modeinHostConfig(now supports arbitrary values for API version >= 1.24). - Added support for
optionsinIPAMConfig - Added a
HealthCheckclass todocker.typesto be used increate_container. - Added an
EndpointSpecclass todocker.typesto be used increate_serviceandupdate_service.
Bugfixes
- Fixed a bug where auth information would not be properly passed to the engine
during a
buildif the client used a credentials store. - Fixed an issue with some exclusion patterns in
build. - Fixed an issue where context files were bundled with the wrong permissions
when calling
buildon Windows. - Fixed an issue where auth info would not be retrieved from its default location on Windows.
- Fixed an issue where lists of
networksincreate_serviceandupdate_servicewouldn't be properly converted for the engine. - Fixed an issue where
endpoint_configincreate_serviceandupdate_servicewould be ignored. endpoint_configincreate_serviceandupdate_servicehas been deprecated in favor ofendpoint_spec- Fixed a bug where
constraintsin aTaskTemplateobject wouldn't be properly converted for the engine. - Fixed an issue where providing a dictionary for
envinContainerSpecwould provoke anAPIErrorwhen sent to the engine. - Fixed a bug where providing an
env_filecontaining empty lines increate_containerwould raise an exception. - Fixed a bug where
detachwas being ignored byexec_start.
Documentation
- Documentation for classes and methods is now included alongside the code as docstrings.
1.10.6
List of PRs / issues for this release
Bugfixes
- Fixed an issue where setting a
NpipeSocketinstance to blocking mode would put it in non-blocking mode and vice-versa.
1.10.5
List of PRs / issues for this release
Bugfixes
- Fixed an issue where concurrent attempts to access to a named pipe by the client would sometimes cause recoverable exceptions to be raised.
1.10.4
List of PRs / issues for this release
Bugfixes
- Fixed an issue where
RestartPolicy.condition_types.ON_FAILUREwould yield an invalid value. - Fixed an issue where the SSL connection adapter would receive an invalid argument.
- Fixed an issue that caused the Client to fail to reach API endpoints when
the provided
base_urlhad a trailing slash. - Fixed a bug where some
environmentvalues increate_containercontaining unicode characters would raise an encoding error. - Fixed a number of issues tied with named pipe transport on Windows.
- Fixed a bug where inclusion patterns in
.dockerignorewould cause some excluded files to appear in the build context on Windows.
Miscellaneous
- Adjusted version requirements for the
requestslibrary. - It is now possible to run the docker-py test suite on Windows.
1.10.3
List of PRs / issues for this release
Bugfixes
- Fixed an issue where identity tokens in configuration files weren't handled by the library.
Miscellaneous
- Increased the default number of connection pools from 10 to 25. This number
can now be configured using the
num_poolsparameter in theClientconstructor.
1.10.2
List of PRs / issues for this release
Bugfixes
- Updated the docker-pycreds dependency as it was causing issues for some users with dependency resolution in applications using docker-py.
1.10.1
List of PRs / issues for this release
Bugfixes
- The docker.utils.types module was removed in favor of docker.types, but some applications imported it explicitly. It has been re-added with an import warning advising to use the new module path.
1.10.0
List of PRs / issues for this release
Features
- Added swarm mode and service management methods. See the documentation for details.
- Added support for IPv6 Docker host addresses in the
Clientconstructor. - Added (read-only) support for the Docker credentials store.
- Added support for custom
auth_configinClient.push. - Added support for
labelsinClient.create_volume. - Added support for
labelsandenable_ipv6inClient.create_network. - Added support for
forceparam inClient.disconnect_container_from_network. - Added support for
pids_limit,sysctls,userns_mode,cpuset_cpus,cpu_shares,mem_reservationandkernel_memoryparameters inClient.create_host_config. - Added support for
link_local_ipsincreate_endpoint_config. - Added support for a
changesparameter inClient.import_image. - Added support for a
versionparameter inClient.from_env.
Bugfixes
- Fixed a bug where
Client.buildwould crash if theconfig.jsonfile contained aHttpHeadersentry. - Fixed a bug where passing
decode=Truein some streaming methods would crash when the daemon's response had an unexpected format. - Fixed a bug where
environmentvalues with unicode characters weren't handled properly increate_container. - Fixed a bug where using the
npipeprotocol would sometimes break withValueError: buffer size must be strictly positive.
Miscellaneous
- Fixed an issue where URL-quoting in docker-py was inconsistent with the quoting done by the Docker CLI client.
- The client now sends TCP upgrade headers to hint potential proxies about connection hijacking.
- The client now defaults to using the
npipeprotocol on Windows.
1.9.0
List of PRs / issues for this release
Features
- Added experimental support for Windows named pipes (
npipe://protocol). - Added support for Block IO constraints in
Client.create_host_config. This includes parametersblkio_weight,blkio_weight_device,device_read_bps,device_write_bps,device_read_iopsanddevice_write_iops. - Added support for the
internalparam inClient.create_network. - Added support for
ipv4_addressandipv6_addressin utils functioncreate_endpoint_config. - Added support for custom user agent setting in the
Clientconstructor. By default, docker-py now also declares itself in theUser-Agentheader.
Bugfixes
- Fixed an issue where the HTTP timeout on streaming responses would sometimes be set incorrectly.
- Fixed an issue where explicit relative paths in
.dockerignorefiles were not being recognized.
1.8.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug where calling
login()against the default registry would fail with the 1.10.x engine - Fixed a bug where values in environment files would be parsed incorrectly if they contained an equal sign.
- Switched to a better supported backport of the
match_hostnamefunction, fixing dependency issues in some environments.
1.8.0
List of PRs / issues for this release
Features
- Added
Client.update_containermethod (Update resource configs of a container) - Added support for gzipped context in
Client.build - Added ability to specify IP address when connecting a container to a network
- Added
tmpfssupport toClient.create_host_config - Added support for the
changesparam inClient.commit - Added support for the
followparam inClient.logs - Added support for the
check_duplicateparam inClient.create_network - Added support for the
decodeparam inClient.pushandClient.pull - Added
docker.from_envshortcut function. Instantiates a client withkwargs_from_env kwargs_from_envnow supports an optionalenvironmentparameter. If present, values will be fetched from this dictionary instead ofos.environ
Bugfixes
- Fixed a bug where TLS verification would fail when using IP addresses
in the certificate's
subjectAltNamefields - Fixed an issue where the default TLS version in TLSConfig would
break in some environments.
docker-pynow uses TLSv1 by default This setting can be overridden using thessl_versionparam inkwargs_from_envor theTLSConfigconstructor - Fixed a bug where
tcphosts would fail to connect to TLS-enabled endpoints - Fixed a bug where loading a valid docker configuration file would fail
- Fixed a bug where some environment variables specified through
create_containerwould be improperly formatted - Fixed a bug where using the unix socket connection would raise an error in some edge-case situations
Miscellaneous
- Default API version is now 1.22 (introduced in Docker 1.10.0)
1.7.2
List of PRs / issues for this release
Bugfixes
- Fixed a bug where TLS verification was improperly executed when providing a custom CA certificate.
1.7.1
List of PRs / issues for this release
Features
- Added support for
shm_sizeinClient.create_host_config
Bugfixes
- Fixed a bug where Dockerfile would sometimes be excluded from the build context.
- Fixed a bug where a docker config file containing unknown keys would raise an exception.
- Fixed an issue with SSL connections behaving improperly when pyOpenSSL was installed in the same environment.
- Several TLS configuration improvements
1.7.0
List of PRs / issues for this release
Features
- Added support for cusom IPAM configuration in
Client.create_network - Added input support to
Client.exec_create - Added support for
stop_signalinClient.create_host_config - Added support for custom HTTP headers in Docker config file.
- Added support for unspecified transfer protocol in
base_urlwhen TLS is enabled.
Bugfixes
- Fixed a bug where the
filtersparameter inClient.volumeswould not be applied properly. - Fixed a bug where memory limits would parse to incorrect values.
- Fixed a bug where the
devicesparameter inClient.create_host_configwould sometimes be misinterpreted. - Fixed a bug where instantiating a
Clientobject would sometimes crash ifbase_urlwas unspecified. - Fixed a bug where an error message related to TLS configuration would link to a non-existent (outdated) docs page.
Miscellaneous
- Processing of
.dockerignorehas been made significantly faster. - Dropped explicit support for Python 3.2
1.6.0
List of PRs / issues for this release
Features
- Added support for the
sinceparam inClient.logs(introduced in API version 1.19) - Added support for the
DOCKER_CONFIGenvironment variable when looking up auth config - Added support for the
streamparam inClient.stats(when set toFalse, allows user to retrieve a single snapshot instead of a constant data stream) - Added support for the
mem_swappiness,oom_kill_disableparams inClient.create_host_config - Added support for build arguments in
Client.buildthrough thebuildargsparam.
Bugfixes
- Fixed a bug where streaming data over HTTPS would sometimes behave incorrectly with Python 3.x
- Fixed a bug where commands containing unicode characters would be incorrectly
handled by
Client.create_container. - Fixed a bug where auth config credentials containing unicode characters would cause failures when pushing / pulling images.
- Setting
tail=0inClient.logsno longer shows past logs. - Fixed a bug where
Client.pullandClient.pushcouldn't handle image names containing a dot.
Miscellaneous
- Default API version is now 1.21 (introduced in Docker 1.9.0)
- Several test improvements and cleanup that should make the suite easier to expand and maintain moving forward.
1.5.0
List of PRs / issues for this release
Features
- Added support for the networking API introduced in Docker 1.9.0
(
Client.networks,Client.create_network,Client.remove_network,Client.inspect_network,Client.connect_container_to_network,Client.disconnect_container_from_network). - Added support for the volumes API introduced in Docker 1.9.0
(
Client.volumes,Client.create_volume,Client.inspect_volume,Client.remove_volume). - Added support for the
group_addparameter increate_host_config. - Added support for the CPU CFS (
cpu_quotaandcpu_period) parameteres increate_host_config. - Added support for the archive API endpoint (
Client.get_archive,Client.put_archive). - Added support for
ps_argsparameter inClient.top.
Bugfixes
- Fixed a bug where specifying volume binds with unicode characters would fail.
- Fixed a bug where providing an explicit protocol in
Client.portwould fail to yield the expected result. - Fixed a bug where the priority protocol returned by
Client.portwould be UDP instead of the expected TCP.
Miscellaneous
- Broke up Client code into several files to facilitate maintenance and contribution.
- Added contributing guidelines to the repository.
1.4.0
List of PRs / issues for this release
Deprecation warning
docker.utils.create_host_configis deprecated in favor ofClient.create_host_config.
Features
- Added
utils.parse_env_fileto support env-files. See docs for usage. - Added support for arbitrary log drivers
- Added support for URL paths in the docker host URL (
base_url) - Drastically improved support for .dockerignore syntax
Bugfixes
- Fixed a bug where exec_inspect would allow invocation when the API version was too low.
- Fixed a bug where
docker.utils.ports.split_portwould break if an open range was provided. - Fixed a bug where invalid image IDs / container IDs could be provided to bypass or reroute request URLs
- Default
base_urlnow adapts depending on the OS (better Windows support) - Fixed a bug where using an integer as the user param in
Client.create_containerwould result in a failure.
Miscellaneous
- Docs fixes
- Integration tests are now run as part of our continuous integration.
- Updated dependency on
sixlibrary
1.3.1
List of PRs / issues for this release
Bugfixes
- Fixed a bug where empty chunks in streams was misinterpreted as EOF.
datetimearguments passed toClient.eventsparameterssinceanduntilare now always considered to be UTC.- Fixed a bug with Docker 1.7.x where the wrong auth headers were being passed
in
Client.build, failing builds that depended on private images. Client.exec_createcan now retrieve theIdkey from a dictionary for its container param.
Miscellaneous
- 404 API status now raises
docker.errors.NotFound. This exception inheritsAPIErrorwhich was used previously. - Docs fixes
- Test fixes
1.3.0
List of PRs / issues for this release
Deprecation warning
- As announced in the 1.2.0 release,
Client.executehas been removed in favor ofClient.exec_createandClient.exec_start.
Features
extra_hostsparameter in host config can now also be provided as a list.- Added support for
memory_limitandmemswap_limitin host config to comply with recent deprecations. - Added support for
volume_driverinClient.create_container - Added support for advanced modes in volume binds (using the
modekey) - Added support for
decodeinClient.build(decodes JSON stream on the fly) - docker-py will now look for login configuration under the new config path,
and fall back to the old
~/.dockercfgpath if not present.
Bugfixes
- Configuration file lookup now also work on platforms that don't define a
$HOMEenvironment variable. - Fixed an issue where pinging a v2 private registry wasn't working properly, preventing users from pushing and pulling.
pullparameter inClient.buildnow defaults toFalse. Fixes a bug where the default options would try to force a pull of non-remote images.- Fixed a bug where getting logs from tty-enabled containers wasn't working properly with more recent versions of Docker
Client.pushandClient.pullwill now raise exceptions if the HTTP status indicates an error.- Fixed a bug with adapter lookup when using the Unix socket adapter (this affected some weird edge cases, see issue #647 for details)
- Fixed a bug where providing
timeout=NonetoClient.stopwould result in an exception despite the usecase being valid. - Added
git@to the list of valid prefixes for remote build paths.
Dependencies
- The websocket-client dependency has been updated to a more recent version.
This new version also supports Python 3.x, making
attach_socketavailable on those versions as well.
Documentation
- Various fixes
1.2.3
List of PRs / issues for this release
Deprecation warning
- Passing host config in the
Client.startmethod is now deprecated. Please use thehost_configinClient.create_containerinstead.
Features
- Added support for
privilegedparam inClient.exec_create(only available in API >= 1.19) - Volume binds can now also be specified as a list of strings.
Bugfixes
- Fixed a bug where the
read_onlyparam in host_config wasn't handled properly. - Fixed a bug in
Client.execute(this method is still deprecated). - The
cpusetparam inClient.create_containeris also passed as theCpusetCpusparam (Cpusetdeprecated in recent versions of the API) - Fixed an issue with integration tests being run inside a container
(
make integration-test) - Fixed a bug where an empty string would be considered a valid container ID or image ID.
- Fixed a bug in
Client.insert
Documentation
- Various fixes
1.2.2
Bugfixes
- Fixed a bug where parameters passed to
Client.exec_resizewould be ignored (#576) - Fixed a bug where auth config wouldn't be resolved properly in
Client.pull(#577)
1.2.1
Bugfixes
- Fixed a bug where the check_resource decorator would break with some argument-passing methods. (#573)
1.2.0
List of PRs / issues for this release
Deprecation warning
Client.executeis being deprecated in favor of the more dev-friendlyClient.exec_startandClient.exec_create. It will be removed in 1.3.0
Features
- Added
exec_create,exec_start,exec_inspectandexec_resizeto client, accurately mirroring the Exec API - Added
auth_configparam toClient.pull(allows to use one-off credentials for this pull request) - Added support for
ipc_modein host config. - Added support for the
log_configparam in host config. - Added support for the
ulimitparam in host config. - Added support for container resource limits in
Client.build. - When a resource identifier (image or container ID) is passed to a Client
method, we now check for
Nonevalues to avoid crashing (now raisesdocker.errors.NullResource) - Added tools to parse port ranges inside the new
docker.utils.portspackage. - Added a
version_infoattribute to thedockerpackage.
Bugfixes
- Fixed a bug in
Client.portwhere absence of a certain key in the container's JSON would raise an error (now just returnsNone) - Fixed a bug with the
truncparameter inClient.containershaving no effect (moved functionality to the client) - Several improvements have been made to the
Client.import_imagemethod. - Fixed pushing / pulling to v2 registries
- Fixed a bug where passing a container dictionary to
Client.commitwould fail
Miscellaneous
- Default API version has been bumped to 1.18 (Docker Engine 1.6.0)
- Several testing coverage improvements
- Docs fixes and improvements
1.1.0
Features
- Added
dockerfileparam support toClient.build(mirrorsdocker build -fbehavior) - Added the ability to specify
'auto'asversioninClient.__init__, allowing the constructor to autodetect the daemon's API version.
Bugfixes
- Fixed a bug where decoding a result stream using the
decodeparameter would break when using Python 3.x - Fixed a bug where some files in
.dockerignoreweren't being handled properly - Fixed
resolve_authconfigissues by bringing it closer to Docker Engine's behavior. This should fix all issues encountered with private registry auth - Fixed an issue where passwords containing a colon weren't being handled properly.
- Bumped
requestsversion requirement, which should fix most of the SSL issues encountered recently.
Miscellaneous
- Several integration test improvements.
- Fixed some unclosed resources in unit tests.
- Several docs improvements.
1.0.0
Features
- Added new
Client.renamemethod (docker rename) - Added now
Client.statsmethod (docker stats) - Added
read_onlyparam support toutils.create_host_configandClient.start(docker run --read-only) - Added
pid_modeparam support toutils.create_host_configandClient.start(docker run --pid='host') - Added
since,untilandfiltersparams toClient.events. - Added
decodeparameter toClient.statsandClient.eventsto decode JSON objects on the fly (False by default).
Bugfixes
- Fixed a bug that caused
Client.buildto crash when the provided source was a remote source.
Miscellaneous
- Default API version has been bumped to 1.17 (Docker Engine 1.5.0)
Client.timeoutis now a public attribute, and users are encouraged to use it when request timeouts need to be changed at runtime.- Added
Client.api_versionas a read-only property. - The
memswap_limitargument inClient.create_containernow accepts string type values similar tomem_limit('6g', '120000k', etc.) - Improved documentation
0.7.2
Features
- Added support for
mac_addressinClient.create_container
Bugfixes
- Fixed a bug where streaming responses (
pull,push,logs, etc.) were unreliable (#300) - Fixed a bug where resolve_authconfig wouldn't properly resolve configuration for private repositories (#468)
- Fixed a bug where some errors wouldn't be properly constructed in
client.py, leading to unhelpful exceptions bubbling up (#466) - Fixed a bug where
Client.buildwould try to close context when externally provided (custom_context == True) (#458) - Fixed an issue in
create_host_configwhere empty sequences wouldn't be interpreted properly (#462)
Miscellaneous
- Added
resolve_authconfigtests.
0.7.1
Bugfixes
setup.pynow indicates a maximum version of requests to work around the boot2docker /assert_hostnamebug.- Removed invalid exception when using the Registry Hub's FQDN when pulling.
- Fixed an issue where early HTTP errors weren't handled properly in streaming responses.
- Fixed a bug where sockets would close unexpectedly using Python 3.x
- Various fixes for integration tests.
Miscellaneous
- Small doc fixes
0.7.0
Breaking changes
- Passing
dnsorvolumes_frominClient.startwith API version < 1.10 will now raise an exception (previously only triggered a warning)
Features
- Added support for
host_configinClient.create_container - Added utility method
docker.utils.create_host_configto help build a properHostConfigdictionary. - Added support for the
pullparameter inClient.build - Added support for the
forcermparameter inClient.build - Added support for
extra_hostsinClient.start - Added support for a custom
timeoutinClient.wait - Added support for custom
.dockercfgloading inClient.login(dockercfg_pathargument)
Bugfixes
- Fixed a bug where some output wouldn't be streamed properly in streaming chunked responses
- Fixed a bug where the
devicesparam didn't recognize the proper delimiter Client.loginnow properly expands theregistryURL if provided.- Fixed a bug where unicode characters in passed for
environmentincreate_containerwould break.
Miscellaneous
- Several unit tests and integration tests improvements.
Clientconstructor now enforces passing theversionparameter as a string.- Build context files are now ordered by filename when creating the archive (for consistency with docker mainline behavior)
0.6.0
- This version introduces breaking changes!
Breaking changes
- The default SSL protocol is now the highest TLS v1.x (was SSL v2.3 before) (Poodle fix)
- The
historycommand now returns a dict instead of a raw JSON string.
Features
- Added the
executecommand. - Added
pauseandunpausecommands. - Added support fo the
cpusetparam increate_container - Added support for host devices (
devicesparam instart) - Added support for the
tailparam inlogs. - Added support for the
filtersparam inimagesandcontainers - The
kwargs_from_envmethod is now available in thedocker.utilsmodule. This should make it easier for boot2docker user to connect to their daemon.
Bugfixes
- Fixed a bug where empty directories weren't correctly included when
providing a context to
Client.build. - Fixed a bug where UNIX socket connections weren't properly cleaned up,
causing
ResourceWarnings to appear in some cases. - Fixed a bug where docker-py would crash if the docker daemon was stopped while reading a streaming response
- Fixed a bug with streaming responses in Python 3
remove_imagenow supports a dict containing anIdkey as itsidparameter (similar to other methods requiring a resource ID)
Documentation
- Added new MkDocs documentation. Currently hosted on ReadTheDocs
Miscellaneous
- Added tests to sdist
- Added a Makefile for running tests in Docker
- Updated Dockerfile
0.5.3
- Fixed attaching when connecting to the daemon over a UNIX socket.
0.5.2
- Fixed a bug where sockets were closed immediately when attaching over TLS.
0.5.1
- Added a
assert_hostnameoption toTLSConfigwhich can be used to disable verification of hostnames. - Fixed SSL not working due to an incorrect version comparison
- Fixed streams not working on Windows
0.5.0
- This version introduces breaking changes!
- Added
insecure_registryparameter inClient.pushandClient.pull. It defaults to False and code pushing to non-HTTPS private registries might break as a result. - Added support for adding and dropping capabilities
- Added support for restart policy
- Added support for string values in
Client.create_container'smem_limit - Added support for
.dockerignorefile inClient.build
Bugfixes
- Fixed timeout behavior in
Client.stop
Miscellaneous
Client.create_containerprovides better validation of thevolumesparameter- Improved integration tests
0.4.0
- This version introduces breaking changes!
- The
base_urlparameter in theClientconstructor should now allow most of theDOCKER_HOSTenvironment values (except for the fd:// protocol)- As a result, URLs that don't specify a port are now invalid (similar to the official client's behavior)
- Added TLS support (see documentation)
Bugfixes
- Fixed an issue with
Client.buildstreamed logs in Python 3
Miscellaneous
- Added unit tests coverage
- Various integration tests fixes
0.3.2
- Default API version is now 1.12 (support for docker 1.0)
- Added new methods
Client.get_imageandClient.load_image(docker saveanddocker load) - Added new method
Client.ping - Added new method
Client.resize Client.buildcan now be provided with a custom context using thecustom_contextparameter.- Added support for
memswap_limitparameter increate_container - Added support for
forceparameter inremove_container - Added support for
forceandnopruneparameters inremove_image - Added support for
timestampsparameter inlogs - Added support for
dns_searchparameter instart - Added support for
network_modeparameter instart - Added support for
sizeparameter incontainers - Added support for
volumes_fromanddnsparameters instart. As of API version >= 1.10, these parameters no longer belong tocreate_container Client.logsnow uses the logs endpoint when API version is sufficient
Bugfixes
- Fixed a bug in pull where the
repo:tagnotation wasn't interpreted properly - Fixed a bug in streaming methods with python 3 (unicode, bytes/str related)
- Fixed a bug in
Client.startwhere legacy notation for volumes wasn't supported anymore.
Miscellaneous
- The client now raises
DockerExceptions when appropriate. You can importDockerException(and its subclasses) from thedocker.errorsmodule to catch them if needed. docker.APIErrorhas been moved to the newdocker.errorsmodule as well.Client.insertis deprecated in API version > 1.11- Improved integration tests should now run much faster.
- There is now a single source of truth for the docker-py version number.
0.3.1
- Default API version is now 1.9
- Streaming responses no longer yield blank lines.
Client.create_containernow supports thedomainnameparameter.volumes_fromparameter inClient.create_containernow supports iterables.- Auth credentials are provided to the docker daemon when using
Client.build(new feature in API version 1.9)
Bugfixes
- Various fixes for response streams (
logs,pull, etc.). - Fixed a bug with
Client.pushwhen using API version < 1.5 - Fixed a bug with API version checks.
Miscellaneous
mockhas been removed from the runtime requirements.- Added installation instructions in the README.
0.3.0
- This version introduces breaking changes!
- Support for API version 1.7 through 1.9 (Docker 0.8.0+)
- Default API version is now 1.8
- The client has been updated to support Requests 2.x.
requests==2.2.1is now the recommended version. - Links can now be specified as tuples in
Client.start(see docs for more information) - Added support for various options in
Client.create_container(network_disabled,cpu_shares,working_dirandentrypoint) Client.attachhas been reworked to work similarly toClient.logsminus the historical data.- Logs can now be streamed using the
streamparameter. - Added support for
tcp://URLs as clientbase_url. - Various auth improvements.
- Added support for custom
Client.buildtimeout.
Bugfixes
- Fixed a bug where determining the protocol of a private registry would sometimes yield the wrong result.
- Fixed a bug where
Client.copywouldn't accept a dict as argument. - Fixed several streaming bugs.
- Removed unused parameter in
Client.import_image. - The client's
base_urlnow tolerates trailing slashes.
Miscellaneous
- Updated integration tests
- Small doc fixes
0.2.3
- Support for API version 1.6
- Added support for links
- Added support for global request timeout
- Added
signalparameter inClient.kill - Added support for
publish_all_portsinClient.start Client.pull,Client.pushandClient.buildcan be streamed now- Added support for websockets in
Client.attach - Fixed ports for Docker 0.6.5+
- Added
Client.eventsmethod (access to the/eventsendpoint) - Changed the way the ports and volumes are provided in
Client.startandClient.create_container̀to make them simpler and more intuitive.
Bugfixes
- Fixed a bug where private registries on HTTPS weren't handled properly
- Fixed a bug where auth would break with Python 3
Miscellaneous
- Test improvements
- Slight doc improvements
0.2.2
- Added support for the
rmparameter inClient.build - Added support for tarball imports in
Client.import_imagethroughdataparameter. - The
commandparameter inClient.create_containeris now optional (for containers that include a default run command)
Bugfixes
- Fixed Python 3 support
- Fixed a bug where anonymous push/pull would break when no authconfig is present
- Fixed a bug where the
quietparameter wouldn't be taken into account inClient.containers - Fixed a bug where
Client.pushwould break when pushing to private registries. - Removed unused
registryparameter inClient.pull. - Removed obsolete custom error message in
Client.create_container.
Miscellaneous
- docker-py is now unit-tested, and Travis-CI has been enabled on the source repository.
0.2.1
- Improvements to the
tox.inifile
Bugfixes
- Fixed a bug where the package would fail with an
ImportErrorif requests was installed usingapt-get - Fixed a bug where
Client.buildwould fail if given apathparameter. - Fixed several bugs in
Client.login. It should now work with API versions 1.4, 1.5. - Please note that
Client.logincurrently doesn't write auth to the.dockercfgfile, thus auth is not persistent when using this method.
0.2.0
- This version introduces breaking changes!
Client.kill,Client.remove_container,Client.remove_image,Client.restart,Client.start,Client.stopandClient.waitdon't support varargs anymore.- Added commands
Client.topandClient.copy - Added
lxc_confparameter toClient.start - Added support for authentication in
Client.pull(API version >=1.5) - Added support for privileged containers.
- Error management overhaul. The new version should be more consistent and
- All methods that expected a container ID as argument now also support a dict
containing an
Idkey. - Added license header to python files.
- Several
README.mdupdates.
Bugfixes
- Fixed several bugs with auth config parsing.
- Fixed a bug in
Client.pushwhere it would raise an exception if the auth config wasn't loaded. - Fixed a bug in
Client.pullwhere private registry images wouldn't be parsed properly if it contained port information.
0.1.5
Client.buildnow uses tempfiles to store build context instead of storing it in memory- Added
nocacheoption toClient.build Client.remove_containernow raises an exception when trying to remove a running containerClient.create_containernow accepts dicts for theenvironmentparameter
Bugfixes
- Fixed a bug in
Client.create_containeron Python 2.6 where unicode commands would fail to be parsed - Fixed a bug in
Client.buildwhere thetagparameter would not be taken into account
0.1.4
- Added support for API connection through UNIX socket (default for docker 0.5.2+)
0.1.3
- The client now tries to load the auth config from
~/.dockercfg. This is necessary to use the push command if API version is >1.0
0.1.2
- Added a
quiet parametertoClient.build(mirrors theqparameter in the API)
0.1.1
- Fixed a bug where the build command would list tar contents before sending the request
- Fixed a bug in
Client.port
0.1.0
- This version introduces breaking changes!
- Switched to server side build system
- Removed the BuilderClient
- Added support for contextual builds
- Added support for remote URL builds
- Added python 3 support
- Added bind mounts support
- Added API version support
- Fixed a bug where
Client.portwould fail if provided with a port of type number - Fixed a bug where
Client._post_jsonwouldn't set the Content-Type header toapplication/json
0.0.6
- Added support for custom loggers in
Client.build - Added
Client.attachcommand - Added support for
ADDcommand in builder - Fixed a bug in
Client.logs - Improved unit tests
0.0.5
- Added tag support for the builder
- Use
shlexto parse plain string commands when creating a container - Fixed several bugs in the builder
- Fixed the
quietoption inClient.images - Unit tests
0.0.4
- Improved error reporting
0.0.3
- Fixed a bug in
Client.tag - Fixed a bug where generated images would be removed after a successful build
0.0.2
- Implemented first version of the builder client