local age=0
local online=0
local offline=0
- local pid device time_p time_n time_u time_d
+ local enabled pid device time_p time_n time_u time_d
network_get_device device $1
}
local uptime="0"
+
+ config_get enabled "$iface" enabled 0
network_get_uptime uptime "$iface"
json_add_object "${iface}"
json_add_int "lost" "$(cat "$MWAN3TRACK_STATUS_DIR/${iface}/LOST")"
json_add_int "turn" "$(cat "$MWAN3TRACK_STATUS_DIR/${iface}/TURN")"
json_add_string "status" "$(cat "$MWAN3TRACK_STATUS_DIR/${iface}/STATUS")"
+ json_add_boolean "enabled" "${enabled}"
json_add_boolean "running" "${running}"
json_add_array "track_ip"
for file in $MWAN3TRACK_STATUS_DIR/${iface}/*; do