copr-backend: install lighttpd's logrotate config for repo hit counting

This commit is contained in:
clime 2017-10-11 13:37:23 +02:00
parent c3dd8e9764
commit 240adfc259
2 changed files with 24 additions and 0 deletions

View file

@ -0,0 +1,21 @@
/var/log/lighttpd/access.log {
rotate 5
daily
missingok
notifempty
prerotate
copr_log_hitcounter.py /var/log/lighttpd/access.log &>/dev/null || :
endscript
postrotate
/usr/bin/killall -HUP lighttpd &>/dev/null || :
endscript
}
/var/log/lighttpd/error.log {
rotate 5
missingok
notifempty
postrotate
/usr/bin/killall -HUP lighttpd &>/dev/null || :
endscript
}

View file

@ -180,6 +180,9 @@
- copy: src="cleanup_vms.sh" dest=/etc/cron.hourly/copr_cleanup_vms.sh mode=755
when: not devel
- name: install lighttpd logrotate config
copy: src="logrotate/lighttpd" dest=/etc/logrotate.d/lighttpd owner=root group=root mode=644
- name: setup monitoring
include: "monitoring.yml"