Note from the publisher: You have managed to find some of our old content and it may be outdated and/or incorrect. Try searching in our docs or on the blog for current information.


I just gave a fun little presentation at the Docker meetup last night at the Heavybit clubhouse. The video of the talk should be online soon, but until then here’s a little recap of the content.

Docker Compose

Even if you don’t use Docker in production yet, Docker Compose can be super helpful in your dev and test environments. Docker Compose is basically a tool to run an arbitrary number of Docker containers at once, linked to each other and otherwise configured in whatever way is specified in a simple YAML file.

Service Dependencies

service dependencies

One use case for Docker Compose in your dev/test environments is managing service dependencies. If, for example, you need a LESS compiler, a linter, a DB, and an app server all running in your dev environment, you can manage them simply with a single docker-compose.yml. If you’re familiar with tools like Foreman to manage multiple processes in your dev environment, Docker Compose can do a very similar job, but far beyond starting each process, it runs each service in its own Docker container, which means all dependencies are very self-contained. Here’s a video example of one of the use cases I covered in my talk last night (there’s no sound in the video):

Complex Test Services

test services

In addition to managing your app’s complex service dependencies, Docker Compose can also lend a hand in running complicated test processes. Distributed stress tests or complex security scans come to mind, but even vanilla browser tests involve a fairly complicated set of intercommunicating processes that can be complex to set up and think about. Docker Compose helps provide some clear structure to this kind of setup as well as parity between dev and test/CI environments. Here’s another quick video demo of this (again, sound-free):

That’s pretty much the skinny on using Docker Compose for your dev and test environments, including CircleCI. All the code used in the videos above is available on GitHub:

The slides from last night’s presentation are also available on SlideShare.

Thanks for reading! And don’t forget to check out the CircleCI docs on Docker to learn how to get up and running with CircleCI for all your docker needs!