108k views
5 votes
What command lists all available Docker networks in your system or swarm cluster?

A) docker network show

B) docker network list

C) docker network ls

D) docker network inspect

User Justmoon
by
7.8k points

1 Answer

3 votes

Final answer:

The correct command to list Docker networks is 'docker network ls'. This command displays all networks managed by Docker along with their details such as ID and name.

Step-by-step explanation:

The command to list all available Docker networks in your system or swarm cluster is C) docker network ls. This command provides a list of all networks that Docker is managing.

For each network, it shows details like the network ID, name, and driver. If you need more information about a specific network, you can use the docker network inspect command, followed by the network's name or ID.

User Levent Divilioglu
by
8.0k points