Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

The preferred mechanism orchestrating Docker in OpenStack is via Heat, rather than treating Docker as a form of hypervisor in OpenStack Nova.

Our initial path towards enabling the use of Docker in OpenStack was to create a driver for Docker in OpenStack Compute (Nova), which enabled a Docker container to be used as if it were a virtual machine.

However, the OpenStack conference in Hong Kong, it became clear that there were disadvantages to this approach. For instance, the standard API extensions expect certain VM-specific functionality, not all of which makes sense in a Docker or container context. Furthermore, using Docker as a VM in Nova also makes it difficult to expose some of the more useful Docker functionality, such as linking containers. For these reasons, we have begun to apply Heat as a better alternative.

OpenStack Heat with Nova OpenStack Heat with Nova (EDIT: OS::Heat::Docker should be DockerInc::Docker::Container) OpenStack Orchestration (Heat) is a solution for providing orchestration of resources inside OpenStack clouds. It provides compatibility with AWS CloudFormation, allowing users to upload templates describing the system that they would like to deploy.

Using the Heat plugin, users may deploy and manage Docker Containers on top of traditional OpenStack deployments, making it compatible with existing OpenStack clouds. Our plugin for Heat has been accepted into OpenStack and will be in the Icehouse release.

See this example for using Heat to orchestrate Docker:

heat_template_version: 2013-05-23 description: Single compute instance running cirros in a Docker container.

In the above example, multiple containers may be created and linked together by simply adding more sections like “my_docker_container”. They’re not constrained by the OpenStack APIs and may leverage the full power of the Docker Remote API.