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

Check for SELinux disabled in Ansible tasks #1162

Merged
merged 1 commit into from
Apr 26, 2022
Merged
Show file tree
Hide file tree
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
4 changes: 3 additions & 1 deletion roles/nvidia-dgx/tasks/configure-raid.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,7 @@

- name: Restore SELinux label on RAID array
command: restorecon /raid
when: ansible_os_family == 'RedHat'
when:
- ansible_os_family == 'RedHat'
- (ansible_selinux is defined) and (ansible_selinux.status != "disabled")
notify: restart cachefilesd
8 changes: 6 additions & 2 deletions roles/slurm/tasks/controller.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,15 @@
target: '/lib64(/.*)?'
setype: mysqld_db_t
state: present
when: ansible_os_family == "RedHat"
when:
- ansible_os_family == "RedHat"
- (ansible_selinux is defined) and (ansible_selinux.status != "disabled")

- name: Apply new SELinux file context to filesystem
command: restorecon -irv /lib64
when: ansible_os_family == "RedHat"
when:
- ansible_os_family == "RedHat"
- (ansible_selinux is defined) and (ansible_selinux.status != "disabled")

- name: start mariadb
systemd:
Expand Down