Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 18 additions & 2 deletions docs/reference/commandline/network_create.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,10 @@ Create a network
## Description

Creates a new network. The `DRIVER` accepts `bridge` or `overlay` which are the
built-in network drivers. If you have installed a third party or your own custom
built-in network drivers on Linux. If you have installed a third party or your own custom
network driver you can specify that `DRIVER` here also. If you don't specify the
`--driver` option, the command automatically creates a `bridge` network for you.
`--driver` option, the command automatically creates a `bridge` network for you
(on Windows, the default is `nat`).
When you install Docker Engine it creates a `bridge` network automatically. This
network corresponds to the `docker0` bridge that Docker Engine has traditionally relied
on. When you launch a new container with `docker run` it automatically connects to
Expand Down Expand Up @@ -68,6 +69,21 @@ Network names must be unique. The Docker daemon attempts to identify naming
conflicts but this is not guaranteed. It is the user's responsibility to avoid
name conflicts.

### Windows network drivers

Native Windows containers use different driver names than Linux. The default
is `nat`. `transparent` attaches containers to a physical network; `overlay`
is available in Swarm mode. For the full list and NIC/IP options, see
[Windows container network drivers](https://learn.microsoft.com/en-us/virtualization/windowscontainers/container-networking/network-drivers-topologies).

```console
# Windows: connect containers to the host's physical network
$ docker network create -d transparent my-transparent
```

To set the address range of a `nat` network, pass `--subnet` and `--gateway`
the same way as on Linux.

### Overlay network limitations

You should create overlay networks with `/24` blocks (the default), which limits
Expand Down