mirror of
https://gitea.0xace.cc/ansible-galaxy/selinux.git
synced 2025-01-18 12:02:18 +00:00
19 lines
516 B
YAML
19 lines
516 B
YAML
---
|
|
- name: Install libselinux-python
|
|
package: name=libselinux-python state=present
|
|
when:
|
|
- ansible_facts['os_family'] == 'RedHat'
|
|
- ansible_facts['distribution_major_version'] <= '7'
|
|
|
|
- name: Install python3-libselinux
|
|
package: name=python3-libselinux state=present
|
|
when:
|
|
- ansible_facts['os_family'] == 'RedHat'
|
|
- ansible_facts['distribution_major_version'] >= '8'
|
|
|
|
- name: 'Set selinux state'
|
|
selinux:
|
|
policy: "{{ selinux_policy }}"
|
|
state: "{{ selinux_state }}"
|
|
notify: Reboot
|