|
Docker Volume Notes
|
$ docker run --volume /home/mount/data:/var/lib/data
----------------------- -------------------
host filesystem container's filesystem
In the host filesystem, this volume is mapped at
/home/mount/data (duh).
$ docker run --volume /var/lib/data
-----------------------
container's filesystem
In the host filesystem, this volume is mapped at
/var/lib/docker/volumes/random-hash/_data.
$ docker run --volume name:/var/lib/data
-------------------
container's filesystem
In the container filesystem, the path to this volume is known by
name and it isn't necessary to know the actual path.