]> git.phdru.name Git - ansible.git/blobdiff - playbooks/roles/logcheck/tasks/main.yml
Feat(logcheck): Install `logcheck-database`
[ansible.git] / playbooks / roles / logcheck / tasks / main.yml
index db94486a3da2762faa2c3700735606c4daab11c0..83980f962ea2b55e4781e92a1a7234f6dae6c7c6 100644 (file)
@@ -5,7 +5,7 @@
     autoremove: yes
     cache_valid_time: 3600
     install_recommends: no
-    name: logcheck
+    name: ['logcheck', 'logcheck-database']
     state: latest
     update_cache: yes
   when: ansible_facts.os_family == 'Debian'
 - name: Configure logcheck - send email to root
   become: true
   lineinfile:
-    path: /etc/logcheck/logcheck.conf
-    regexp: '^SENDMAILTO="root"$'
-    line: 'SENDMAILTO="root"'
-    insertafter: '^SENDMAILTO="logcheck"$'
-
-- name: Configure logcheck - do not send email to logcheck
-  become: true
-  lineinfile:
-    path: /etc/logcheck/logcheck.conf
-    regexp: '^SENDMAILTO="logcheck"$'
-    state: absent
+    path: /etc/aliases
+    line: 'logcheck: root'
 
 - name: Update logcheck ignore files
   become: true