Change History


  • Implemented update of container settings (i.e. memory limit, cpu shares) without a need for resetting the container, where supported by more recent Docker hosts.
  • Version-dependent client features such as volumes and networks have been consolidated into a dictionary-type property features.
  • Added support for the Docker SDK for Python 2.x. Version 1.x is still supported. Using 2.x and a sufficiently recent Docker host adds the following functionality:
    • The restart_policy setting in the host config can be updated at runtime.
    • stop_timeout is passed to the container on creation. Whereas Docker-Map has been supporting this setting for a while now, this will also apply when manually stopping a container (e.g. through the command line).
  • Added healthcheck: Adds a health check command to containers, if the Docker host and the API client supports it.
  • start_delay: Simply adds a delay of x seconds after a container has been started. Can be used on older Docker hosts to prevent race conditions during container linking.
  • Added Dockerfile properties labels, shell, stopsignal, and healthcheck. There is however no verification if the Docker host supports these commands.
  • Added serialization: Container maps now have a method as_dict(), that return all contents as a nested Python dictionary structure. Passing this in as the initial argument of ContainerMap yields a copy of the original map.
  • Input validation and conversion is no longer performed immediately when configuration properties are being set, but deferred to a later step. This will likely not have any practical implications for most users, since conversion still happens automatically before merge operations and before the configuration is being used. It can also be invoked by calling clean().
  • All tuple input lists from now accept dictionaries with their named parameters as input.
  • For consistency with other properties, the order of arguments in the HostConfig tuple have been changed. It is not path, host_path, readonly (optional).


  • Fixed Python 3 compatibility.
  • Minor internal refactoring.


  • Restart uses the configured stop signal for the container.
  • Added option to restart exec commands on container restart.
  • The result (i.e. the id) of exec commands is now returned by the runner.


  • Added checks on configured ip addresses and link-local ips. Additional general improvements to container network endpoint check against configuration.
  • Added checks on volume driver and driver options.
  • After an unsuccessful stop attempt, added another wait period so that the container has time to process the SIGKILL signal issued by Docker.
  • Process a single MapConfigId as valid input.
  • Moved CmdCheck flags to input module.


  • The pull_images() action also pulls present images by default (i.e. updates them from the registry). This was optional before, and can be prevented by passing pull_all_images=False, only pulling missing image tags.
  • Internal cleanup of converting input into configuration ids.


  • Included main process id in state data, so that implementations can detect a container restart more easily.
  • Handling deprecation of the force argument when tagging images in newer Docker releases. The tag is added automatically depending on the detected API version.
  • Fixed update check of container network mode referring to another container.
  • Additional minor bugfix from previous prereleases.


  • Added volumes: Where the Docker host supports it, volumes can now be configured with additional properties such as driver and options. The original workaround of Docker containers sharing anonymous volumes no longer applies in this case.
  • The default path of volumes in attaches volumes can now be defined, by using a dictionary or list of tuples. They no longer have to (but still can) be set in volumes.
  • Where the Docker host supports named volumes, container-side paths of uses items can be overridden, provided that they are referring to attached volumes created through another container.
  • Removed clients property from ContainerConfiguration. It caused too much complexity in responding to supported client features. In addition, it was likely to break dependency paths. clients is however still available.


  • MappingDockerClient now wraps all exceptions so that partial results, i.e. actions that already have been performed on clients. It raises a ActionRunnerException, which provides information about the client and action performed, partial results through results(), but also the possibility to re-trigger the original traceback using reraise().
  • Similarly, direct calls to the utility client DockerClientWrapper, such as cleanup_containers() now return a PartialResultsError.
  • Added signal() method to client.
  • Images have been integrated into the dependency resolution. Images of a container and all of its dependencies can now be pulled with the new command pull_images().
  • Authentication information for the Docker registry can now be added to and are considered during login and image pull actions.
  • Added a built-in group __all__, that applies to all containers or even all configured maps on MappingDockerClient.
  • Several adaptions which makes it easier for programs and libraries using the API to evaluate changes.
  • More fixes to image dependency check, so that cleanup_images() now works reliably. Removals can also be forced where applicable.
  • Implemented CLI, missing from 0.8.0b1.
  • Various bugfixes from 0.8.0b1.


  • Added groups: Generally an action (e.g. startup of containers) can now be run at once on multiple items. In order to make input easier, groups can be added to a map that refers to multiple configurations. Dependencies that multiple items have in common will only be followed once.
  • Added forced update: Not all differences between the container configuration and an existing instance can be detected automatically. A parameter force_update can now trigger an update of particular containers.
  • Added networks: Docker networks can now be configured on a map. Referring to them in the property networks from one or multiple container configurations will create them automatically. The former network setting has been renamed to network_mode for disambiguation.


  • More sensible solution of Issue #15, not changing user-defined link aliases. Doing so could cause name resolution issues.


  • Minor fixes for compatibility with newer Docker hosts.
  • Followup fixes from Issue #15.


  • Fixed case where exec_create does not return anything, as when commands are started immediately (e.g. the CLI, Issue #17).
  • Improved accuracy of comparing the container command from the configuration with the container inspection info.
  • Added parser for CLI top command, as needed for inspecting exec commands.


  • Fixed command line generator for case where cmd is used as a keyword argument (Issue #16).


  • Fixed recursive dependency resolution order.
  • Setting an alias name is always optional for container links, even if ContainerLinks tuple is used directly.


  • Added version method to command line generator.

  • Internal refactoring: Moved configuration elements to individual modules. If you get any import errors from this update, please check if you are using convenience imports such as from dockermap.api import ContainerMap instead of the modules where the classes are implemented.

  • Fixed ContainerMap.containers attribute access to work as documented.


    The default iteration behavior has also changed. Similar to and ContainerMap.volumes, it generates items. Before iteration was returning keys, as usual for dictionaries.

  • Fixes for use of alternative client implementations (e.g. CLI, Issue #12).

  • Fixed link argument for command line generator (Issue #13).

  • Added replacement for invalid characters in generated host names (Issue #15).


  • Refactoring of policy framework. The monolithic client action functions have been divided into separate modules for improving maintainability and testing. This also makes it easier to add more functionality. A few minor issues with updating containers and executing commands were resolved during this change.
  • Added an experimental command line generator.


  • Added evaluation of .dockerignore files.
  • Several bugfixes from 0.6.6b1.


  • Added arguments to set additional image tags after build.
  • Added default_tag property to container maps.
  • Minor refactoring. Possibly breaks compatibility in custom policy implementations:
    • has been renamed to reset_updated().
    • ensure_image() argument pull_latest has been renamed to pull.
    • has been renamed to pull_before_update.
    • has been renamed to image_name() and changed order of arguments for allowing defaults.


  • Better support for IPv6 addresses. Added ipv6 flag to port bindings and interfaces_ipv6 property to client configuration.
  • Command elements are converted into strings so that Dockerfiles with a numeric command line element do not raise errors.


  • Fixed exception on stopping a container configuration when the container does not exist.


  • Improved fixed behavior when merging container maps and embedded container configurations. Can also be used for creating copies.
  • Added stop_timeout argument to remove_all_containers.
  • Fixed transfer of configuration variables into client instance.


  • Added stop_signal for customizing the signal that is used for shutting down or restarting containers.
  • Minor changes in docs and log messages.
  • Fixed image cache update with multiple tags.
  • Bugfix in Dockerfile module.


  • Many more Python 3 fixes (PR #10).
  • Cleaned up logging; only using default levels.
  • Port bindings are passed as lists to the API, allowing container ports to be published to multiple host ports and interfaces.


  • Added exec_commands to start additional commands (e.g. scripts) along with the container.
  • Container links are now passed as lists to the API, so that the same container can be linked with multiple aliases.
  • Various compatibility fixes with Python 3 (PR #9).
  • Bugfixes on container restart and configuration merge.


  • Bugfixes for network mode and volume check of inherited configurations.
  • Fixed deprecation warnings from docker-py.
  • Added option to prepare attached volumes with local commands instead of temporary containers, for clients that support it.


  • Added network modes and their dependencies. Attached volumes are no longer enabled for networking.
  • Added per-container stop timeout. Also applies to restart.


  • Adjusted volume path inspection to use Mounts on newer Docker API versions. Fixes issues with the update policy.


  • Implemented HostConfig during container creation, which is preferred over passing arguments during start since API v1.15. For older API versions, start keyword arguments will be used.
  • Added configuration inheritance and abstract configurations.
  • Changed log functions to better fit Python logging.
  • Minor fixes in merge functions.
  • Bug fix in tag / repository partitioning (PR #7).


  • Added automated container start, log, and removal for scripts or single commands.
  • Added separate exception type for map integrity check failures.
  • Aliases for host volumes are now optional.
  • Minor bugfixes in late value resolution, container cleanup, and input conversion.


  • Added check for changes in environment, command, and network settings in update policy.
  • Added optional pull before new container creation.
  • Revised dependency resolution for avoiding duplicate actions and detecting circular dependencies more reliably.
  • Fix for handling missing container names in cleanup method.
  • Allow for merging empty dictionary keys.


  • Fix for missing container names and tags.
  • Exclude default client name from host name.


  • Fixed error handling in build (issue #6).
  • New command_workdir for setting the working directory in DockerFiles.
  • Enhanced file adding functions in DockerFile to return build context paths.
  • Fixed volume consistency check in update policy.
  • Additional minor updates.


  • Extended late value resolution to custom types.
  • Various bugfixes (e.g. PR #5).


  • Possibility to use ‘lazy’ values in various settings (e.g. port bindings, volume aliases, host volumes, and user).
  • Consider read-only option for inherited volumes in uses property.
  • Further update policy fixes.
  • Python 3 compatibility fixes (PR #4).


  • Added convenience imports in api module.


  • Added host and domain name setting.
  • Improved update requirement detection.
  • Fixed restart policy.


  • Moved container handling logic to policy classes.
  • Better support for multiple maps and multiple clients.
  • Added startup, shutdown, and update actions, referring to variable policy implementations.
  • Added persistent flag to container configurations to differentiate during cleanup processes.
  • Added methods for merging container maps and configurations.
  • It is no longer required to use the wrapped client DockerClientWrapper.
  • More flexible logging.


  • Minor fix in DockerFile creation.


  • Only setup fix, no functional changes.


  • Various bugfixes related to repository prefix, shortcuts, users.


  • Added YAML import.
  • Added default host root path and repository prefix.
  • Added Docker registry actions to wrapper.
  • Fixed issues related to starting containers.


Initial release.