infrastructure/ansible/roles/base/tasks/logrotate.yml

18 lines
364 B
YAML

- name: Install logrotate
package:
name: logrotate
become: true
- name: Enable logrotate timer
service:
name: logrotate.timer
enabled: true
become: true
when: ansible_os_family == 'Archlinux'
- name: logrotate fail2ban config
template:
src: files/fail2ban-logrotate
dest: /etc/logrotate.d/fail2ban
mode: "0600"
become: true