mirror of
https://dev.iopsys.eu/feed/iopsys.git
synced 2025-12-10 07:44:50 +01:00
netmode: temporary testnet object to query online status
This commit is contained in:
parent
593da2e6f8
commit
e4221b84f0
1 changed files with 18 additions and 0 deletions
18
netmode/files/usr/libexec/rpcd/testnet
Executable file
18
netmode/files/usr/libexec/rpcd/testnet
Executable file
|
|
@ -0,0 +1,18 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
. /usr/share/libubox/jshn.sh
|
||||||
|
|
||||||
|
case "$1" in
|
||||||
|
list)
|
||||||
|
echo '{ "status" : {} }'
|
||||||
|
;;
|
||||||
|
call)
|
||||||
|
case "$2" in
|
||||||
|
status)
|
||||||
|
json_load "$(cat /tmp/internet_connection_status 2>/dev/null)"
|
||||||
|
json_dump
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
Loading…
Add table
Reference in a new issue