Skip to content

Commit 43ccdea

Browse files
committed
Docker: Stop record when session failure
Signed-off-by: Viet Nguyen Duc <[email protected]>
1 parent 4c35f64 commit 43ccdea

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Video/video.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ else
239239

240240
wait_for_api_respond
241241
while curl --noproxy "*" -H "Authorization: Basic ${BASIC_AUTH}" -sk --request GET ${NODE_STATUS_ENDPOINT} >/tmp/status.json; do
242-
session_id=$(jq -r "${JQ_SESSION_ID_QUERY}" /tmp/status.json)
242+
session_id=$(jq -e "${JQ_SESSION_ID_QUERY}" /tmp/status.json || echo "null")
243243
if [[ "$session_id" != "null" && "$session_id" != "" && "$session_id" != "reserved" && "$recording_started" = "false" ]]; then
244244
echo "$(date -u +"${ts_format}") [${process_name}] - Session: $session_id is created"
245245
return_list=($(bash ${VIDEO_CONFIG_DIRECTORY}/video_graphQLQuery.sh "$session_id"))

0 commit comments

Comments
 (0)