mirror of
https://github.com/falcosecurity/falco.git
synced 2025-10-21 19:44:57 +00:00
Rotate logs (#347)
* Reopen file/program outputs on SIGUSR1 When signaled with SIGUSR1, close and reopen file and program based outputs. This is useful when combined with logrotate to rotate logs. * Example logrotate config Example logrotate config that relies on SIGUSR1 to rotate logs. * Ensure options exist for all outputs Options may not be provided for some outputs (like stdout), so create an empty set of options in that case.
This commit is contained in:
7
examples/logrotate/falco
Normal file
7
examples/logrotate/falco
Normal file
@@ -0,0 +1,7 @@
|
||||
/var/log/falco-events.log {
|
||||
rotate 5
|
||||
size 1M
|
||||
postrotate
|
||||
/usr/bin/killall -USR1 falco
|
||||
endscript
|
||||
}
|
Reference in New Issue
Block a user