LinuxCommandLibrary

docker-volume

manage Docker persistent data volumes

TLDR

List volumes

$ docker volume ls
copy
Create a volume
$ docker volume create [name]
copy
Inspect a volume
$ docker volume inspect [volume]
copy
Remove a volume
$ docker volume rm [volume]
copy
Remove unused volumes
$ docker volume prune
copy
Create with driver options
$ docker volume create --driver local --opt type=nfs --opt o=addr=[host],rw --opt device=:[path] [name]
copy

SYNOPSIS

docker volume command [options]

DESCRIPTION

docker volume manages Docker volumes. Volumes persist data independently of containers and are the preferred mechanism for persisting data generated by containers.

SUBCOMMANDS

ls

List volumes.
create
Create a volume.
inspect
Display detailed information.
rm
Remove volumes.
prune
Remove unused volumes.

SEE ALSO

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community