dovecot: add logrotate config
This commit is contained in:
parent
20bf96c155
commit
40efa84fcf
12
roles/mail/files/logrotate.d/dovecot
Normal file
12
roles/mail/files/logrotate.d/dovecot
Normal file
@ -0,0 +1,12 @@
|
||||
/var/log/dovecot/*.log {
|
||||
weekly
|
||||
rotate 4
|
||||
missingok
|
||||
notifempty
|
||||
compress
|
||||
delaycompress
|
||||
sharedscripts
|
||||
postrotate
|
||||
doveadm log reopen
|
||||
endscript
|
||||
}
|
@ -46,6 +46,9 @@
|
||||
- dovecot/local.conf
|
||||
notify: Restart dovecot
|
||||
|
||||
- name: Configure logrotate for dovecot
|
||||
copy: src=logrotate.d/dovecot dest=/etc/logrotate.d/dovecot
|
||||
|
||||
- name: Ensure dovecot certificates are available
|
||||
command: openssl req -x509 -nodes -newkey rsa:2048 -keyout /etc/dovecot/ssl/{{ mail_server }}.key -out /etc/dovecot/ssl/{{ mail_server }}.crt -days 730 -subj "/CN={{ mail_server }}" creates=/etc/dovecot/ssl/{{ mail_server }}.crt
|
||||
notify: Restart dovecot
|
||||
|
Loading…
Reference in New Issue
Block a user