ansible-roles/roles/mongodb_server/tasks/selinux.yml
2021-12-01 19:13:34 +01:00

15 lines
265 B
YAML

---
- name: Set correct SELinux label
sefcontext:
target: "{{ mongo_db_path }}"
setype: mongod_var_lib_t
state: present
tags: mongo
- name: Restore SELinux contexts
command: restorecon -R {{ mongo_db_path }}
changed_when: False
tags: mongo