2016-10-14 18:30:36 -04:00
|
|
|
---
|
|
|
|
title: "network disconnect"
|
|
|
|
description: "The network disconnect command description and usage"
|
2016-11-03 18:48:30 -04:00
|
|
|
keywords: "network, disconnect, user-defined"
|
2016-10-14 18:30:36 -04:00
|
|
|
---
|
2015-09-28 21:57:03 -04:00
|
|
|
|
|
|
|
# network disconnect
|
|
|
|
|
2016-07-07 14:43:18 -04:00
|
|
|
```markdown
|
|
|
|
Usage: docker network disconnect [OPTIONS] NETWORK CONTAINER
|
2015-09-28 21:57:03 -04:00
|
|
|
|
2016-07-07 14:43:18 -04:00
|
|
|
Disconnect a container from a network
|
2016-01-12 23:56:36 -05:00
|
|
|
|
2016-07-07 14:43:18 -04:00
|
|
|
Options:
|
|
|
|
-f, --force Force the container to disconnect from a network
|
|
|
|
--help Print usage
|
|
|
|
```
|
2015-09-28 21:57:03 -04:00
|
|
|
|
2017-02-07 18:42:48 -05:00
|
|
|
## Description
|
|
|
|
|
|
|
|
Disconnects a container from a network. The container must be running to
|
|
|
|
disconnect it from the network.
|
|
|
|
|
|
|
|
## Examples
|
2015-09-28 21:57:03 -04:00
|
|
|
|
2015-10-18 19:47:32 -04:00
|
|
|
```bash
|
2015-09-28 21:57:03 -04:00
|
|
|
$ docker network disconnect multi-host-network container1
|
|
|
|
```
|
|
|
|
|
2015-10-18 19:47:32 -04:00
|
|
|
|
2017-02-07 18:42:48 -05:00
|
|
|
## Related commands
|
2015-10-18 19:47:32 -04:00
|
|
|
|
|
|
|
* [network inspect](network_inspect.md)
|
|
|
|
* [network connect](network_connect.md)
|
|
|
|
* [network create](network_create.md)
|
|
|
|
* [network ls](network_ls.md)
|
|
|
|
* [network rm](network_rm.md)
|
2016-10-18 00:36:52 -04:00
|
|
|
* [network prune](network_prune.md)
|
2016-10-20 23:24:28 -04:00
|
|
|
* [Understand Docker container networks](https://docs.docker.com/engine/userguide/networking/)
|