Skip to content

Commit

Permalink
Decrease verbosity, seems stable
Browse files Browse the repository at this point in the history
  • Loading branch information
brablc committed Jun 5, 2024
1 parent 3956b6c commit 7bb0ee7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions integrations/zenduty.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ jq -r \
"summary": .summary
}' $input_file > $request_file

log_info "Request file:"
jq . $request_file 2>/dev/null || cat $request_file
test -n "$VERBOSE" && log_info "Request file:"
test -n "$VERBOSE" && ( jq . $request_file 2>/dev/null || cat $request_file )

url="https://www.zenduty.com/api/events/${ZENDUTY_API_KEY}/"
curl -s -X POST "$url" -H 'Content-Type: application/json' -d @$request_file >$response_file
Expand All @@ -62,8 +62,8 @@ if [ $return_code -ne 0 ]; then
log_error "Curl failed with code $return_code"
fi

log_info "Response file:"
jq . $response_file 2>/dev/null || cat $response_file
test -n "$VERBOSE" && log_info "Response file:"
test -n "$VERBOSE" && ( jq . $response_file 2>/dev/null || cat $response_file )

if [[ $action == "resolve" ]]; then
rm -f $request_file
Expand Down

0 comments on commit 7bb0ee7

Please sign in to comment.