File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
content/reference/compose-file Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -1572,6 +1572,11 @@ in the form:
15721572- ` CONTAINER` is `port | range`.
15731573- ` PROTOCOL` restricts ports to a specified protocol either `tcp` or `udp`(optional). Default is `tcp`.
15741574
1575+ >[!CAUTION]
1576+ >
1577+ >If you do not specify an IP address (such as 127.0.0.1) and it binds to all interfaces then any machine on the same network could
1578+ >potentially have access to the container. This could be especially dangerous if the container is exposed to the internet.
1579+
15751580Ports can be either a single value or a range. `HOST` and `CONTAINER` must use equivalent ranges.
15761581
15771582You can either specify both ports (`HOST:CONTAINER`), or just the container port. In the latter case,
@@ -1580,6 +1585,8 @@ the container runtime automatically allocates any unassigned port of the host.
15801585` HOST:CONTAINER` should always be specified as a (quoted) string, to avoid conflicts
15811586with [YAML base-60 float](https://yaml.org/type/float.html).
15821587
1588+
1589+
15831590IPv6 addresses can be enclosed in square brackets.
15841591
15851592Examples :
You can’t perform that action at this time.
0 commit comments