I've a base_image Dockerfile with a
VOLUME /var/log
Now I use the base_image in another Dockerfile as base for work_image and there is put some content in /var/log
.
But if I start a container with the work_image the volume directory /var/log
is empty.
The content of volume is not initialized during image creation how it is documented here:
https://docs.docker.com/engine/reference/builder/#volume
I've also tried to put another VOLUME /var/log
directive in the work_image Dockerfile. But no change.
Is this as bug or how this should work?
Thx Markus
docker container inspect <container>
for each container and see what volumes they are using.