fix(deploy): validate complete smoke logs (#1)
This commit is contained in:
@@ -121,9 +121,19 @@ dotnet run --project "$PROJECT" --configuration "$BUILD_CONFIGURATION" --no-buil
|
||||
wait "$host_pid"
|
||||
host_pid=''
|
||||
|
||||
jq -e 'select(.event == "host.direct-traffic" and .status == "verified")' "$host_log" >/dev/null
|
||||
jq -e 'select(.event == "host.deregistered" and .status == "complete")' "$host_log" >/dev/null
|
||||
jq -e 'select(.event == "join.direct-traffic" and .status == "verified")' "$join_log" >/dev/null
|
||||
jq -e 'select(.event == "join.outcome-report" and .status == "accepted")' "$join_log" >/dev/null
|
||||
if ! jq -s -e '
|
||||
any(.[]; .event == "host.direct-traffic" and .status == "verified")
|
||||
and any(.[]; .event == "host.deregistered" and .status == "complete")
|
||||
' "$host_log" >/dev/null; then
|
||||
printf 'Host diagnostic did not complete authenticated traffic and deregistration.\n' >&2
|
||||
exit 1
|
||||
fi
|
||||
if ! jq -s -e '
|
||||
any(.[]; .event == "join.direct-traffic" and .status == "verified")
|
||||
and any(.[]; .event == "join.outcome-report" and .status == "accepted")
|
||||
' "$join_log" >/dev/null; then
|
||||
printf 'Join diagnostic did not complete authenticated traffic and outcome reporting.\n' >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
printf 'Rendezvous deployment smoke passed: HTTP live/ready and authenticated UDP mediation/direct traffic.\n'
|
||||
|
||||
Reference in New Issue
Block a user