visio.chapril.org-tools/rapport_activite/probe_api.sh

32 lines
601 B
Bash
Raw Normal View History

2020-11-26 15:40:14 +01:00
#!/bin/bash
json=$(curl http://localhost:8080/colibri/stats 2> /dev/null)
function show
{
local key="$1"
local value=$(echo "$json" | jshon -e $key -u)
printf " $key=$value"
}
printf "$(date +%FT%T)"
#show "current_timestamp"
#show "version"
show "total_conferences_created"
show "total_failed_conferences"
show "total_conferences_completed"
show "largest_conference"
show "total_conference_seconds"
show "total_bytes_received"
show "total_bytes_sent"
show "total_participants"
show "conferences"
show "participants"
show "videochannels"
show "endpoints_sending_audio"
printf "\n"