Update docs for host networking (#19783)

* Update docs for host networking

* Update content/desktop/networking.md

---------

Co-authored-by: Allie Sadler <102604716+aevesdocker@users.noreply.github.com>
This commit is contained in:
Andreas Heck 2024-04-11 11:27:31 +02:00 committed by GitHub
parent f9fd521e79
commit 0fde22482a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 8 additions and 3 deletions

View File

@ -185,5 +185,8 @@ container to random ports on the host.
$ docker run -d -P --name webserver nginx
```
Alternatively, you can also use [host networking](../network/drivers/host.md#docker-desktop)
to give the container direct access to the network stack of the host.
See the [run command](../reference/cli/docker/container/run.md) for more details on
publish options used with `docker run`.

View File

@ -23,8 +23,10 @@ host.
Nginx listen on a different port, see the
[documentation for the `nginx` image](https://hub.docker.com/_/nginx/)
- The `host` networking driver only works on Linux hosts, and is not supported
on Docker Desktop for Mac, Docker Desktop for Windows, or Docker EE for Windows Server.
- The `host` networking driver only works on Linux hosts, but is availabe as a
[beta feature](../../release-lifecycle.md#beta) on Docker Desktop version 4.29
and later for Mac, Windows, and Linux. To enable this feature, navigate to the
**Features in development** tab in **Settings**, and then select **Enable host networking**.
## Procedure
@ -63,4 +65,4 @@ host.
- [Standalone networking tutorial](network-tutorial-standalone.md)
- [Overlay networking tutorial](network-tutorial-overlay.md)
- [Macvlan networking tutorial](network-tutorial-macvlan.md)
- [Macvlan networking tutorial](network-tutorial-macvlan.md)