mirror of https://github.com/docker/cli.git
Update /etc/hosts when linked container is restarted
Docker-DCO-1.1-Signed-off-by: Victor Vieux <vieux@docker.com> (github: vieux)
This commit is contained in:
parent
8b869694be
commit
bbea6aa42d
|
@ -432,6 +432,9 @@ mechanism to communicate with a linked container by its alias:
|
||||||
$ docker run -d --name servicename busybox sleep 30
|
$ docker run -d --name servicename busybox sleep 30
|
||||||
$ docker run -i -t --link servicename:servicealias busybox ping -c 1 servicealias
|
$ docker run -i -t --link servicename:servicealias busybox ping -c 1 servicealias
|
||||||
|
|
||||||
|
If you restart the source container (`servicename` in this case), the recipient
|
||||||
|
container's `/etc/hosts` entry will be automatically updated.
|
||||||
|
|
||||||
## VOLUME (Shared Filesystems)
|
## VOLUME (Shared Filesystems)
|
||||||
|
|
||||||
-v=[]: Create a bind mount with: [host-dir]:[container-dir]:[rw|ro].
|
-v=[]: Create a bind mount with: [host-dir]:[container-dir]:[rw|ro].
|
||||||
|
|
Loading…
Reference in New Issue