Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: add fapolicy exclusion rule #239

Merged
merged 2 commits into from
Apr 6, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -64,23 +64,25 @@
command: vdsm-tool configure --force
changed_when: True

- name: add vdsm-mom allow rule to fapolicy
copy:
dest: /etc/fapolicyd/rules.d/32-allow-vdsm-mom.rules
group: fapolicyd
mode: '0644'
remote_src: yes
content: |
allow perm=any trust=1 : dir=/etc/vdsm/mom.d/ ftype=text/x-lisp
when: ansible_distribution == 'RedHat'

- name: collect facts about system services
service_facts:

- name: restart fapolicy service
systemd:
state: restarted
name: fapolicyd
- block:
- name: add vdsm-mom allow rule to fapolicy
copy:
dest: /etc/fapolicyd/rules.d/32-allow-vdsm-mom.rules
group: fapolicyd
mode: '0644'
remote_src: yes
content: |
allow perm=any trust=1 : dir=/etc/vdsm/mom.d/ ftype=text/x-lisp

- name: restart fapolicy service
systemd:
state: restarted
name: fapolicyd

when:
- ansible_distribution == 'RedHat'
hbraha marked this conversation as resolved.
Show resolved Hide resolved
- "'fapolicyd.service' in services"
- ansible_facts.services["fapolicyd.service"].state == 'running'