summaryrefslogtreecommitdiffstats
path: root/network/unbound/unbound.logrotate
diff options
context:
space:
mode:
Diffstat (limited to 'network/unbound/unbound.logrotate')
-rw-r--r--network/unbound/unbound.logrotate11
1 files changed, 11 insertions, 0 deletions
diff --git a/network/unbound/unbound.logrotate b/network/unbound/unbound.logrotate
new file mode 100644
index 0000000000..a00c8f0951
--- /dev/null
+++ b/network/unbound/unbound.logrotate
@@ -0,0 +1,11 @@
+/var/log/unbound/unbound.log {
+ su unbound unbound
+ notifempty
+ missingok
+ rotate 7
+ postrotate
+ # Try using unbound-control to start a new log
+ # On fail, fall back to using a HUP signal
+ /usr/sbin/unbound-control log_reopen || bash /etc/rc.d/rc.unbound reload
+ endscript
+}