fix: Add pipefail option to shell command in verify.yml
Resolves ansible-lint risky-shell-pipe violation by adding 'set -o pipefail' to shell task that uses pipes.
This commit is contained in:
@@ -105,6 +105,7 @@
|
||||
|
||||
- name: Verify no critical errors in logs
|
||||
ansible.builtin.shell: |
|
||||
set -o pipefail
|
||||
if grep -i "error" /var/log/named/default.log | grep -v "error reporting" > /dev/null; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user