Merge pull request #125 from sicwolf/patch-1

Wrong destination folder in container
This commit is contained in:
Misty Stanley-Jones 2016-10-19 14:50:31 -07:00 committed by GitHub
commit cdaef772f8
1 changed files with 6 additions and 6 deletions

View File

@ -99,11 +99,11 @@ In addition to creating a volume using the `-v` flag you can also mount a
directory from your Docker engine's host into a container.
```bash
$ docker run -d -P --name web -v /src/webapp:/opt/webapp training/webapp python app.py
$ docker run -d -P --name web -v /src/webapp:/webapp training/webapp python app.py
```
This command mounts the host directory, `/src/webapp`, into the container at
`/opt/webapp`. If the path `/opt/webapp` already exists inside the container's
`/webapp`. If the path `/webapp` already exists inside the container's
image, the `/src/webapp` mount overlays but does not remove the pre-existing
content. Once the mount is removed, the content is accessible again. This is
consistent with the expected behavior of the `mount` command.
@ -152,7 +152,7 @@ Docker volumes default to mount in read-write mode, but you can also set it to
be mounted read-only.
```bash
$ docker run -d -P --name web -v /src/webapp:/opt/webapp:ro training/webapp python app.py
$ docker run -d -P --name web -v /src/webapp:/webapp:ro training/webapp python app.py
```
Here you've mounted the same `/src/webapp` directory but you've added the `ro`
@ -180,12 +180,12 @@ the other examples.
The following command creates a named volume, called `my-named-volume`,
using the `flocker` volume driver, and makes it available within the container
at `/opt/webapp`:
at `/webapp`:
```bash
$ docker run -d -P \
--volume-driver=flocker \
-v my-named-volume:/opt/webapp \
-v my-named-volume:/webapp \
--name web training/webapp python app.py
```
@ -199,7 +199,7 @@ using the `docker volume create` command.
$ docker volume create -d flocker -o size=20GB my-named-volume
$ docker run -d -P \
-v my-named-volume:/opt/webapp \
-v my-named-volume:/webapp \
--name web training/webapp python app.py
```