Basically the same issue was actually reported recently in MESOS-3413 [1]. The discussion in there resulted in a code change in the Mesos framework for ArangoDB [2]. One first has to create a volume with some container path and then add a volume to the ContainerInfo when launching the docker container that uses the same path as host path for the volume. Now the container path needs to be absolute, like /data. Files that are now being created below /data show up in the persistent volume and newly launched containers with the same mapping can reuse the data. Not that obvious in my opinion but it works :-)
[1] https://issues.apache.org/jira/browse/MESOS-3413 [2] https://github.com/arangodb/arangodb-mesos-framework/commit/98ccbdbaa5ae41f83b02ca42e7325746ad044099 p.s.: looks like jira is currently down ... On 23/06/16 16:56, Hendrik Haddorp wrote: > Hi, > > I'm trying to write a Mesos framework that should create persistent > volumes and then start a Docker container that uses this. So far I was > able to dynamically reserve resources (cpu, memory and disk) and create > a persistent volume in the reserved disk space. I'm also able to launch > a Docker container. I just can't figure out how to connect these > correctly. I either get told that some fields are not set correctly, end > up with mounting a path on the host system or nothing at all seems to > happen. > > Would be nice if somebody could show how a TaskInfo protobuf would need > to get filled to achieve this. > > thanks, > Hendrik

