Hier werden die Unterschiede zwischen zwei Versionen der Seite angezeigt.
knowledge_base:linux:docker:clone-volume [2022/05/31 21:19] – angelegt julian.lemmerich | knowledge_base:linux:docker:clone-volume [2022/06/11 14:35] (aktuell) – copy over and translate to english julian.lemmerich | ||
---|---|---|---|
Zeile 1: | Zeile 1: | ||
- | ====== | + | ====== |
- | https:// | + | Angelehnt an [https:// |
+ | |||
+ | The current '' | ||
+ | |||
+ | Copy the clone-docker-volumes script from alaub' | ||
+ | |||
+ | <code bash> | ||
+ | wget https:// | ||
+ | chmod +x clone-docker-volumes.sh | ||
+ | </ | ||
+ | |||
+ | this command shows current volumes | ||
+ | |||
+ | <code bash> | ||
+ | docker volume ls | ||
+ | # creates Volume_NEW and copies Volume_OLD to Volume_NEW | ||
+ | clone-docker-volumes.sh volume_OLD volume_NEW | ||
+ | </ | ||
+ | |||
+ | Cleaning up afterwards: | ||
+ | |||
+ | First command shows all volumes that are not assigned to a container. | ||
+ | |||
+ | < | ||
+ | docker volume ls -f dangling=true | ||
+ | docker volume rm volume_ALT | ||
+ | </ | ||
+ | |||
+ | Done! |