-
-
Notifications
You must be signed in to change notification settings - Fork 104
Open
Labels
DebuggingDebugging CasesDebugging Cases
Description
When trying to apply control 3.3.4 in the conditional to check whether 'ufw' is present before restarting the service, the condition will never be able to be assessed as the error is in stderr rather than in stdout. It was constantly failing:
- name: 3.3.4 Ensure suspicious packets are logged | restart ufw after changes in /etc/ufw/sysctl.conf
service:
name: ufw
state: restarted
when:
- UFWEnable
- "'not found' not in ufw_check.stdout"
... thus the last line above should be replaced with the following line, after which it happily skips the control and completes without issues:
- "'not found' not in ufw_check.stderr"
... and some more proof:
Metadata
Metadata
Assignees
Labels
DebuggingDebugging CasesDebugging Cases