ClusterHQ/flocker — pull request #993 by wallrj (2014-11-25 18:01:44+00:00)
Title: Use Bind rather than Volumes to when matching containers with Flocker volumes

I've been investigating this again with @dwgebler and @tomprince,

@tomprince pointed out that the docker API now allows volume Bind configuration to be specified at container creation time.

That means that the Bind information should always be available when we call inspect_container.

So we can use the Bind configuration rather than the Volumes information in our DockerClient.list method to construct Volume instances.

The Volumes and Bind configuration returned by inspect will only differ if a container is started without bind mounts to match all the container / image volumes. In this case, Volumes will also include the default mount points that Docker creates.
But we're not interested in those.

Fixes https://clusterhq.atlassian.net/browse/FLOC-940