dont be quiet on first grep

This commit is contained in:
m0duspwnens
2021-05-14 08:56:42 -04:00
parent d3af06e7a4
commit 3859f6464a

View File

@@ -926,7 +926,7 @@ if [[ $success != 0 ]]; then SO_ERROR=1; fi
# Check entire setup log for errors or unexpected salt states and ensure cron jobs are not reporting errors to root's mailbox # Check entire setup log for errors or unexpected salt states and ensure cron jobs are not reporting errors to root's mailbox
# Ignore "Status .* was not found" due to output from salt http.query or http.wait_for_successful_query states used with retry # Ignore "Status .* was not found" due to output from salt http.query or http.wait_for_successful_query states used with retry
if grep -q -E "ERROR|Result: False" $setup_log | grep -qvE "Status .* was not found" || [[ -s /var/spool/mail/root && "$setup_type" == "iso" ]]; then if grep -E "ERROR|Result: False" $setup_log | grep -qvE "Status .* was not found" || [[ -s /var/spool/mail/root && "$setup_type" == "iso" ]]; then
SO_ERROR=1 SO_ERROR=1
grep --color=never "ERROR" "$setup_log" | grep -qvE "Status .* was not found" > "$error_log" grep --color=never "ERROR" "$setup_log" | grep -qvE "Status .* was not found" > "$error_log"