Reset Skript added
This commit is contained in:
parent
87beac8437
commit
ccc1973623
1 changed files with 15 additions and 0 deletions
15
scripts/X-kill-all-containers-and-prune-system
Normal file
15
scripts/X-kill-all-containers-and-prune-system
Normal file
|
|
@ -0,0 +1,15 @@
|
||||||
|
#!/bin/bash
|
||||||
|
# kill, remove, prune everything Docker-related
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
echo "Killing all containers..."
|
||||||
|
docker kill $(docker ps -q) 2>/dev/null || true
|
||||||
|
|
||||||
|
echo "Removing all containers..."
|
||||||
|
docker rm -f $(docker ps -aq) 2>/dev/null || true
|
||||||
|
|
||||||
|
echo "Pruning system..."
|
||||||
|
docker system prune -a -f --volumes
|
||||||
|
|
||||||
|
echo "Done."
|
||||||
Loading…
Add table
Reference in a new issue