mirror of
https://github.com/krislamo/vagrant-easyredmine
synced 2024-12-16 07:20:36 +00:00
add logrotate config for redmine
This commit is contained in:
parent
88ad75b6f2
commit
6a9ecf43d8
@ -147,3 +147,9 @@
|
|||||||
job="({{ redmine_root_dir }}/script/redmine_fetch_changesets 2>&1 | sed '/install RDoc/d') >> {{ redmine_root_dir }}/log/redmine_fetch_changesets"
|
job="({{ redmine_root_dir }}/script/redmine_fetch_changesets 2>&1 | sed '/install RDoc/d') >> {{ redmine_root_dir }}/log/redmine_fetch_changesets"
|
||||||
user='{{ redmine_owner }}'
|
user='{{ redmine_owner }}'
|
||||||
become: yes
|
become: yes
|
||||||
|
|
||||||
|
- name: adding logrotate
|
||||||
|
template: dest='/etc/logrotate.d/redmine'
|
||||||
|
src=redmine_logrotate.j2
|
||||||
|
mode=0644
|
||||||
|
become: yes
|
||||||
|
9
roles/easyredmine/templates/redmine_logrotate.j2
Normal file
9
roles/easyredmine/templates/redmine_logrotate.j2
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
{{ redmine_root_dir }}/log/*.log {
|
||||||
|
su {{ redmine_owner }} {{ redmine_owner }}
|
||||||
|
daily
|
||||||
|
missingok
|
||||||
|
rotate 7
|
||||||
|
compress
|
||||||
|
notifempty
|
||||||
|
copytruncate
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user