Last active
August 29, 2015 14:28
-
-
Save batmat/33d4bdb18d962b25ade6 to your computer and use it in GitHub Desktop.
Small PoC script showing the disk usage can grow very quickly with forgotten volumes (and it's not removable through docker rm[i])
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -eou pipefail | |
COUNT=5 | |
SIZE_IN_MB=500 | |
while [[ $COUNT > 0 ]]; do | |
sudo du -sm /var/lib/docker | |
docker run -v /pouet debian fallocate -l ${SIZE_IN_MB}M /pouet/test.img | |
COUNT=$(( $COUNT - 1 )) | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment