From 4f283c2d8660b4649f29b6861872dcbd797a7f8a Mon Sep 17 00:00:00 2001 From: Jason Ertel Date: Tue, 23 Nov 2021 14:52:40 -0500 Subject: [PATCH] Suppres grep output --- salt/common/tools/sbin/soup | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/salt/common/tools/sbin/soup b/salt/common/tools/sbin/soup index fc6694ec2..2244f2735 100755 --- a/salt/common/tools/sbin/soup +++ b/salt/common/tools/sbin/soup @@ -841,7 +841,7 @@ apply_hotfix() { if [[ "$INSTALLEDVERSION" == "2.3.90" && "$HOTFIXVERSION" == "WAZUH" ]] ; then FILE="/nsm/wazuh/etc/ossec.conf" echo "Detecting if ossec.conf needs corrected..." - if head -1 $FILE | grep "xml version"; then + if head -1 $FILE | grep -q "xml version"; then echo "$FILE has an XML header; removing" sed -i 1d $FILE so-wazuh-restart