From 9ef57d6e987dc15c02a7cfec64834ebd9aed954f Mon Sep 17 00:00:00 2001 From: kaotisk Date: Sat, 30 Sep 2023 02:55:51 +0300 Subject: At last a logrotating script --- bin/ak-logrotate | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100755 bin/ak-logrotate diff --git a/bin/ak-logrotate b/bin/ak-logrotate new file mode 100755 index 0000000..7bfee72 --- /dev/null +++ b/bin/ak-logrotate @@ -0,0 +1,7 @@ +#!/bin/bash + +tar cvfz $AK_ARCHIVESDIR/logs_$(date -u +%s).tar.gz $AK_WORKDIR/akd.log $AK_WORKDIR/akd.err $AK_WORKDIR/logs + +cat /dev/null > $AK_WORKDIR/akd.log +cat /dev/null > $AK_WORKDIR/akd.err +cat /dev/null > $AK_WORKDIR/logs -- cgit v1.2.3