Skip to content
This repository was archived by the owner on Dec 26, 2020. It is now read-only.

Commit 7b934e4

Browse files
author
Sebastian Gumprich
committed
Add another conditional
1 parent b17bd65 commit 7b934e4

File tree

1 file changed

+1
-1
lines changed
  • roles/ansible-ssh-hardening/tasks

1 file changed

+1
-1
lines changed

roles/ansible-ssh-hardening/tasks/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131

3232
- name: Create selinux custom policy drop folder
3333
file: path={{ custom_selinux_dir }} state=directory owner=root group=root mode=0750
34-
when: not ssh_use_pam and sestatus.stdout != 'Disabled'
34+
when: not ssh_use_pam and sestatus.stdout != 'Disabled' and selinux_installed.rc == 0
3535

3636
# The following tasks only get executed when selinux is in state enforcing and UsePam is "no".
3737
# See this issue for more info: https://github.com/hardening-io/ansible-ssh-hardening/issues/23

0 commit comments

Comments
 (0)