Merge pull request #970 from srd424/disk-check-fix
Check disk usage of filesystem hosting recordings
This commit is contained in:
@@ -1,9 +1,10 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
set -x
|
set -x
|
||||||
used="$(df -h / | tail -n1 | awk '{print $5}')"
|
|
||||||
|
source /etc/birdnet/birdnet.conf
|
||||||
|
used="$(df -h ${EXTRACTED} | tail -n1 | awk '{print $5}')"
|
||||||
|
|
||||||
if [ "${used//%}" -ge 95 ]; then
|
if [ "${used//%}" -ge 95 ]; then
|
||||||
source /etc/birdnet/birdnet.conf
|
|
||||||
|
|
||||||
case $FULL_DISK in
|
case $FULL_DISK in
|
||||||
purge) echo "Removing oldest data"
|
purge) echo "Removing oldest data"
|
||||||
|
|||||||
Reference in New Issue
Block a user