mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-08-29 23:08:06 +02:00
THE HUGE REFACTORING CALENDER WEEK 33; Optimized Matrix and during this updated variables, and implemented better reset and cleanup mode handling, also solved some initial setup bugs
This commit is contained in:
43
roles/sys-svc-docker/Administration.md
Normal file
43
roles/sys-svc-docker/Administration.md
Normal file
@@ -0,0 +1,43 @@
|
||||
# Administration 🛠️
|
||||
|
||||
## List Unused Volumes
|
||||
```bash
|
||||
docker volume ls -q -f "dangling=true"
|
||||
```
|
||||
|
||||
## Remove All Unused Volumes
|
||||
```bash
|
||||
docker volume rm $(docker volume ls -q -f "dangling=true")
|
||||
```
|
||||
|
||||
## Network Issues Fixes
|
||||
```bash
|
||||
docker stop $(docker ps -a -q)
|
||||
docker rm $(docker ps -a -q)
|
||||
docker network prune -f
|
||||
systemctl stop docker
|
||||
rm -fv /var/lib/docker/network/files/local-kv.db
|
||||
systemctl start docker
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
# Warning ⚠️
|
||||
|
||||
**Caution:** The following instructions will delete **all Docker containers and volumes** on your server.
|
||||
Make sure you have backups or that you're certain you want to clean your Docker environment completely.
|
||||
|
||||
---
|
||||
|
||||
## Cleaning Up Docker Containers and Volumes 🧹
|
||||
|
||||
### Delete All Docker Containers
|
||||
```bash
|
||||
docker stop $(docker ps -a -q)
|
||||
docker rm $(docker ps -a -q)
|
||||
```
|
||||
|
||||
### Delete All Docker Volumes
|
||||
```bash
|
||||
docker volume rm $(docker volume ls -q)
|
||||
```
|
Reference in New Issue
Block a user