mirror of https://github.com/docker/docs.git
Update _index.md
Make the port mapping table easier to read.
This commit is contained in:
parent
be0dbbc0ed
commit
fe2fd57aec
|
@ -38,12 +38,12 @@ This creates a firewall rule in the host,
|
||||||
mapping a container port to a port on the Docker host to the outside world.
|
mapping a container port to a port on the Docker host to the outside world.
|
||||||
Here are some examples:
|
Here are some examples:
|
||||||
|
|
||||||
| Flag value | Description |
|
| Flag value | Description |
|
||||||
| ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `-p 8080:80` | Map TCP port 80 in the container to port `8080` on the Docker host. |
|
| `-p 8080:80` | Map port `8080` on the Docker host to TCP port `80` in the container. |
|
||||||
| `-p 192.168.1.100:8080:80` | Map TCP port 80 in the container to port `8080` on the Docker host for connections to host IP `192.168.1.100`. |
|
| `-p 192.168.1.100:8080:80` | Map port `8080` on the Docker host IP `192.168.1.100` to TCP port `80` in the container. |
|
||||||
| `-p 8080:80/udp` | Map UDP port 80 in the container to port `8080` on the Docker host. |
|
| `-p 8080:80/udp` | Map port `8080` on the Docker host to UDP port `80` in the container. |
|
||||||
| `-p 8080:80/tcp -p 8080:80/udp` | Map TCP port 80 in the container to TCP port `8080` on the Docker host, and map UDP port 80 in the container to UDP port `8080` on the Docker host. |
|
| `-p 8080:80/tcp -p 8080:80/udp` | Map TCP port `8080` on the Docker host to TCP port `80` in the container, and map UDP port `8080` on the Docker host to UDP port `80` in the container.|
|
||||||
|
|
||||||
> **Important**
|
> **Important**
|
||||||
>
|
>
|
||||||
|
|
Loading…
Reference in New Issue