Skip to content

Commit

Permalink
feat(hourly): add hourly job def to pillar.example
Browse files Browse the repository at this point in the history
  • Loading branch information
mdschmitt committed Jan 13, 2022
1 parent 7b5676b commit 77374a4
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions pillar.example
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,22 @@ logrotate:
- postrotate
- /bin/kill -HUP `cat /var/run/syslogd.pid 2> /dev/null` 2> /dev/null || true
- endscript
nginx_high_traf:
path:
- /var/log/nginx_high_traf/*.log
config:
- hourly
- missingok
- rotate {{ 30 * 24 }} # keep 1 month's worth of hourly logs
- compress
- notifempty
- dateext
- dateformat .%Y-%m-%d-%H00
- olddir /var/log/nginx_high_traf/archive
- sharedscripts
- postrotate
- '[ -r /var/run/nginx_high_traf.pid ] && kill -USR1 $(cat /var/run/nginx_high_traf.pid)'
- endscript
nginx:
contents: |
/var/log/nginx/*.log{
Expand Down

0 comments on commit 77374a4

Please sign in to comment.