mirror of https://github.com/docker/docs.git
Option --network not valid at least with the latest docker (#755)
--network option not valid with docker version 1.11.2. So, proposing to change --network to --net --network=my-bridge-network
This commit is contained in:
parent
d915deff95
commit
9aa7706799
|
@ -131,9 +131,9 @@ To build web applications that act in concert but do so securely, create a
|
|||
network. Networks, by definition, provide complete isolation for containers. You
|
||||
can add containers to a network when you first run a container.
|
||||
|
||||
Launch a container running a PostgreSQL database and pass it the `--network=my-bridge-network` flag to connect it to your new network:
|
||||
Launch a container running a PostgreSQL database and pass it the `--net=my-bridge-network` flag to connect it to your new network:
|
||||
|
||||
$ docker run -d --network=my-bridge-network --name db training/postgres
|
||||
$ docker run -d --net=my-bridge-network --name db training/postgres
|
||||
|
||||
If you inspect your `my-bridge-network` you'll see it has a container attached.
|
||||
You can also inspect your container to see where it is connected:
|
||||
|
|
Loading…
Reference in New Issue