1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

update htbt script

This commit is contained in:
winlin 2015-10-26 14:50:16 +08:00
parent 3933819686
commit 6f6d495a19

View file

@ -1,4 +1,5 @@
#/bin/bash #/bin/bash
ip=`ifconfig 2>&1|grep "inet addr"|grep -v "127"|awk '{print $2}'|awk -F ':' '{print $2}'`
for ((;;)); do for ((;;)); do
echo "heatbeat at `date`" echo "heatbeat at `date`"
curl 'http://ossrs.net:8085/api/v1/servers' -H 'Content-Type: text/html' --data-binary "{\"ip\":\"${ip}\",\"device_id\":\"respberry-pi2\"}" && echo "" curl 'http://ossrs.net:8085/api/v1/servers' -H 'Content-Type: text/html' --data-binary "{\"ip\":\"${ip}\",\"device_id\":\"respberry-pi2\"}" && echo ""