summaryrefslogtreecommitdiff
path: root/user/chrony/chrony.logrotate
diff options
context:
space:
mode:
authorDan Theisen <djt@hxx.in>2018-06-26 04:28:07 -0700
committerDan Theisen <djt@hxx.in>2018-06-26 18:44:39 -0700
commitb00cda0fc4fbeb6c64801e8180c2a2feeb288766 (patch)
tree8f376def6b56eebebfbefb2208118925b4001622 /user/chrony/chrony.logrotate
parent586c518d3cdca10f7c83ca73efd2a41a1f295d4a (diff)
downloadpackages-b00cda0fc4fbeb6c64801e8180c2a2feeb288766.tar.gz
packages-b00cda0fc4fbeb6c64801e8180c2a2feeb288766.tar.bz2
packages-b00cda0fc4fbeb6c64801e8180c2a2feeb288766.tar.xz
packages-b00cda0fc4fbeb6c64801e8180c2a2feeb288766.zip
user/chrony: new package, import from alpine, clean up
Diffstat (limited to 'user/chrony/chrony.logrotate')
-rw-r--r--user/chrony/chrony.logrotate12
1 files changed, 12 insertions, 0 deletions
diff --git a/user/chrony/chrony.logrotate b/user/chrony/chrony.logrotate
new file mode 100644
index 000000000..4461a3063
--- /dev/null
+++ b/user/chrony/chrony.logrotate
@@ -0,0 +1,12 @@
+/var/log/chrony/*.log {
+ missingok
+ sharedscripts
+ postrotate
+ PASSWORD=`awk '$1 ~ /^1$/ {print $2; exit}' /etc/chrony/chrony.keys`
+ cat << EOF | /usr/bin/chronyc | sed '/^200 OK$/d'
+ password $PASSWORD
+ cyclelogs
+EOF
+ endscript
+}
+