title: Confused about multiple different containers using a single data volume containers
body: <p>I've been investigating docker recently, and I moving on to start to look at data volume containers, and how I can persist information between sessions, and I'm alittle confused.</p>
  
  <p>Can a single data volume container be used in the majority of cases?</p>
  
  <p>Lets take a simple one, the library/postgres image, in its dockerfile it exposes a volume /var/lib/postgresql/data  Suppose I mapped that locally to /docker/db_data in a single container setup, I understand that the contents of /var/lib/postgresql/data would be found in my laptops /docker/db_data folder.</p>
  
  <p>But what happens if you want to branch out and have another container running Jenkins, for example, which exposes /var/jenkins_home as a volume.  Initially I would have mapped that to another folder on my laptop, like for example /docker/jenkins_data.</p>
  
  <p>But if I want to enable a data volume container to manage both of these, how can this be done?</p>
  
  <p>Lets say we want to map both containers to directories on my laptop, /docker/db_data and /docker/jenkins_data</p>
  
  <p>Or am I doing this wrong, would it be considered best practises if I used 2 data volume containers, and kept it simple?</p>