summaryrefslogtreecommitdiffstats
path: root/roles/common/tasks/clamav.yml
diff options
context:
space:
mode:
authorGuilhem Moulin <guilhem@fripost.org>2016-09-18 17:55:33 +0200
committerGuilhem Moulin <guilhem@fripost.org>2016-09-18 17:55:33 +0200
commita4ecc629b38e9d9d4cf918d6095112347c141e55 (patch)
tree654def79ff5bab9a947887ee2ce2942ac3082d7d /roles/common/tasks/clamav.yml
parent87dc808939fbc740c3742e10ce4d23a4c7099c07 (diff)
Postfix: ensure common aliases are present.
Diffstat (limited to 'roles/common/tasks/clamav.yml')
-rw-r--r--roles/common/tasks/clamav.yml10
1 files changed, 10 insertions, 0 deletions
diff --git a/roles/common/tasks/clamav.yml b/roles/common/tasks/clamav.yml
index 3579d31..1c68598 100644
--- a/roles/common/tasks/clamav.yml
+++ b/roles/common/tasks/clamav.yml
@@ -2,20 +2,30 @@
apt: pkg={{ item }}
with_items:
- clamav
- clamav-daemon
- clamav-freshclam
- name: Configure FreshClam
template: src=etc/clamav/freshclam.conf.j2
dest=/etc/clamav/freshclam.conf
owner=clamav group=adm
mode=0444
tags: freshclam
notify:
- Restart freshclam
- name: Start ClamAV
service: name={{ item }} state=started
with_items:
- clamav-daemon
- clamav-freshclam
+
+- name: Add a 'clamav' alias
+ lineinfile: dest=/etc/aliases create=yes
+ regexp="^clamav{{':'}} "
+ line="clamav{{':'}} root"
+
+- name: Compile the static local Postfix database
+ postmap: cmd=postalias src=/etc/aliases db=cdb
+ owner=root group=root
+ mode=0644