I edited the first post, because i forgot the colon in the first
docker run command. So i am not actually creating a volume, but just linking a named one.
You are absolutely right @dmaze, the posts above are not relevant. I am aware of the boot2docker issue, but this issue here should not be connected to this.
I did not create a
VOLUME in a Dockerfile so there is nothing to show here, i just created it manually with
docker volume create --name data and created the files while working with another container.
Can you epxplain while the first run command creates an new volume and copies the files - or was this just because of the missing colon? Just to be clear, the files are not part of the image, but reside in the already created named volume.
I tried to run the command with the
nocopy flag, but all i get is this:
invalid value "data:/home/pub:nocopy" for flag -v: bad mode specified: nocopy
Mounting from the
var/lib/docker tree was only for testing purposes and reference.
@dvohra Mounting an empty volume is of course blazing fast. Why would the size of the volume affect the runtime of the
docker runcommand - this seems to be irrelevant when mounting host-directories directly?
In my eyes the behaviour is not reasonable. If i am wrong i would gladly appreciate any explanations - otherwise i am filing a bug report in the github repo.