Getting started with Docker + Parallels on OS X (using Homebrew)
Update: Sep 2016: This is no longer relevant; best to download Docker for Mac which uses xhyve to virtualize the Docker Engine environment and Linux kernel-specific features on OS X. This allows for much easier sharing of files between your local machine and docker containers.
Want to use Docker on OS X? At the moment, the OS X kernel does not directly support containers like Docker or OpenVZ. So you have to run a VM with docker installed. You then use the Docker CLI to interact with the Docker (daemon) running on the VM. The whole process is actually very easy to setup now that Docker Machine supports the Parallels driver.
Assumptions: You already have Parallels (11, Business or Pro Edition) and Homebrew installed.
$> brew update # need to brew with a recent version $> brew upgrade $> brew install docker docker-machine docker-machine-parallels … grab some coffee… $> docker-machine create -d parallels dev1 $> eval `docker-machine env dev1` $> docker run hello-world
You are now ready to use Docker, Docker Composer and even Docker Swarm.