mirror of
https://github.com/autistic-symposium/backend-and-orchestration-toolkit.git
synced 2025-06-08 06:53:00 -04:00
43 lines
563 B
Markdown
43 lines
563 B
Markdown
## useful tricks for docker
|
|
|
|
<br>
|
|
|
|
|
|
#### shared folders
|
|
|
|
Removing some of the default shared folders can decrease CPU usage (e.g. remove `/Volumes` and `/private`).
|
|
|
|
Check storage with:
|
|
|
|
```
|
|
docker info |grep Storage
|
|
```
|
|
|
|
|
|
<br>
|
|
|
|
#### performance
|
|
|
|
In case of performance problems you can run:
|
|
|
|
```
|
|
docker run --rm=true -it --privileged --pid=host \
|
|
<image name> /usr/bin/top
|
|
```
|
|
|
|
<br>
|
|
|
|
#### cleaning up
|
|
|
|
See disk space:
|
|
|
|
```
|
|
docker system df
|
|
```
|
|
|
|
|
|
Remove stopped containers, dangling images, the build cache, and unused networks:
|
|
|
|
```
|
|
docker system prune
|
|
```
|