mirror of
https://github.com/wsargent/docker-cheat-sheet.git
synced 2025-09-22 05:40:50 +02:00
Added -v to container cleanup command. This will never delete bind-mount volumes, and this will cleanup otherwise orphaned managed volumes.
This commit is contained in:
parent
9351555a34
commit
7557c4b685
1 changed files with 1 additions and 1 deletions
|
@ -392,7 +392,7 @@ docker ps -a | grep 'weeks ago' | awk '{print $1}' | xargs docker rm
|
||||||
### Delete stopped containers
|
### Delete stopped containers
|
||||||
|
|
||||||
```
|
```
|
||||||
docker rm `docker ps -a -q -f status=exited`
|
docker rm -v `docker ps -a -q -f status=exited`
|
||||||
```
|
```
|
||||||
|
|
||||||
### Delete dangling images
|
### Delete dangling images
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue