diff --git a/tasks/restrictions_configfile.yml b/tasks/restrictions_configfile.yml index fa61b24..ce3b77f 100644 --- a/tasks/restrictions_configfile.yml +++ b/tasks/restrictions_configfile.yml @@ -1,6 +1,6 @@ --- - name: Check for Include directory - shell: "awk '/Include/ { print $2; }' /etc/ssh/sshd_config" + shell: "awk '/^[^#]*Include/ { print $2; }' /etc/ssh/sshd_config" changed_when: False register: ssh_hardening_includedir