Editing Docker volume ls

Jump to navigation Jump to search

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.

Latest revision Your text
Line 1: Line 1:
{{lc}}<code>[[docker volume]] ls</code> List all the volumes known to [[Docker]]
+
<code>[[docker volume]] ls</code> https://docs.docker.com/engine/reference/commandline/volume_ls/
* https://docs.docker.com/engine/reference/commandline/volume_ls/
 
 
 
* <code>[[docker volume]] ls</code>
 
* <code>[[docker volume ls --format]]</code>
 
* <code>[[docker volume ls --help]]</code>
 
  
 
== Examples ==
 
== Examples ==
  
[[docker volume]] ls
+
  docker volume ls -f dangling=true
DRIVER              VOLUME NAME
 
local              0a92e3e2af047db06a590cf0d3164f4a6e039158abab8d4d8e4f0b84e7add2cb
 
local              1e7c62f7b303215a8e12be9ce49ff9a3ea866d44ecfbe8030e6064eb39378d43
 
local              1e9458c18988bf76a6b5186a86a1f9d0b18b0c0a9dccaa913f5bee213fcb8bc4
 
local              your_named_volume_1
 
local              your_named_volume_2
 
 
 
docker volume ls
 
DRIVER    VOLUME NAME
 
 
 
  docker volume ls -f [[dangling]]=true
 
 
  docker volume ls -f dangling=false
 
  docker volume ls -f dangling=false
  
Line 45: Line 29:
  
 
== Related commands ==
 
== Related commands ==
* <code>[[docker system df -v]]</code> show docker [[disk usage]]
+
* <code>[[docker system df]]</code>
* <code>[[docker system prune]]</code>
+
 
* <code>[[docker system prune --volumes]]</code>
 
* <code>[[docker volume create]] --name VOLUME_NAME</code>
 
* <code>[[docker-compose]]</code>
 
* <code>[[docker inspect]]</code>
 
* <code>[[docker volume inspect]]</code>
 
* <code>[[podman volume ls]]</code>
 
Docker list volumes associated with all containers:
 
* <code><nowiki>docker ps -a --format '{{ .ID }}' | xargs -I {} docker inspect -f '{{ .Name }}{{ printf "\n" }}{{ range .Mounts }}{{ printf "\n\t" }}{{ .Type }} {{ if eq .Type "bind" }}{{ .Source }}{{ end }}{{ .Name }} => {{ .Destination }}{{ end }}{{ printf "\n" }}' {}</nowiki></code>
 
* [[mount]] | grep [[^/dev/]] | grep -v /etc | awk '{print $3}'
 
  
 
== See also ==
 
== See also ==
 
* {{Docker Volumes}}
 
* {{Docker Volumes}}
 
* {{du}}
 
* {{du}}
 
+
* {{docker}}
  
  
 
[[Category:Docker]]
 
[[Category:Docker]]

Please note that all contributions to wikieduonline may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see Wikieduonline:Copyrights for details). Do not submit copyrighted work without permission!

Cancel Editing help (opens in new window)

Advertising: