Fix redundant log writing

Fixes calling "armbian-ramlog write" twice on systems with logrotate systemd unit.
This commit is contained in:
NekoB0x 2021-03-25 01:02:23 +02:00 committed by GitHub
parent c1ef2aeba9
commit 540d7abd88
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,2 +1,6 @@
#!/bin/sh
# Only run on systems where logrotate is a cron job
if [ -f /lib/systemd/system/logrotate.timer ]; then
exit 0
fi
/usr/lib/armbian/armbian-ramlog write >/dev/null 2>&1