Docker has introduced a top-level volume management command from version 1.9 in order to manage the persistent filesystem effectively. The volume management command is capable of managing data volumes that are part of the Docker host. In addition to that, it also helps us to extend the Docker persistent capability using pluggable volume drivers (Flocker, GlusterFS, and so on). You can find the list of supported plugins at https://docs.docker.com/engine/extend/legacy_plugins/.
The docker volume command supports four subcommands as listed here:
- create: This creates a new volume
- inspect: This displays detailed information about one or more volumes
- ls: This lists the volumes in the Docker host
- rm: This removes a volume
Let's quickly explore the volume management command through a few examples. You can create a volume using the docker volume create subcommand, as shown here:
$ sudo...