Skip to content

Commit

Permalink
Permissions issue with auto-prune
Browse files Browse the repository at this point in the history
  • Loading branch information
yorickdowne committed Nov 7, 2021
1 parent 41b6e3c commit 1afa5e4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions auto-prune.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ for var in "$@"; do
done


FREE_DISK=$(df -P /var/lib/docker/volumes | awk '/[0-9]%/{print $(NF-2)}')
TOTAL_DISK=$(df -P /var/lib/docker/volumes | awk '/[0-9]%/{print $(NF-4)}')
FREE_DISK=$(df -P /var/lib/docker/ | awk '/[0-9]%/{print $(NF-2)}')
TOTAL_DISK=$(df -P /var/lib/docker/ | awk '/[0-9]%/{print $(NF-4)}')
PERCENT_FREE=$(echo "percent = ($FREE_DISK / $TOTAL_DISK) * 100; scale = 0; percent / 1" | bc -l)
FREE_DISK_GB=$(echo "$FREE_DISK / 1024 / 1024" | bc)

Expand Down

0 comments on commit 1afa5e4

Please sign in to comment.