1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-feeds.git synced 2025-03-09 15:40:03 +00:00

Use server script to detect if MPTCP is enabled on interface

This commit is contained in:
Ycarus (Yannick Chabanois) 2021-04-14 21:07:26 +02:00
parent fa375333df
commit d36d5c7f65
2 changed files with 66 additions and 4 deletions

View file

@ -1108,6 +1108,10 @@ if [ "$(uci -q get openmptcprouter.$OMR_TRACKER_INTERFACE.lc)" = "" ] || [ $(($(
}
config_load openmptcprouter
config_foreach traceboxmtutest server
[ "$(uci -q get openmptcprouter.settings.tracebox)" = "0" ] && {
mptcpsupport="$(omr-mptcp-intf $OMR_TRACKER_DEVICE)"
[ -n "$mptcpsupport" ] && uci -q set openmptcprouter.$OMR_TRACKER_INTERFACE.mptcp_status="$mptcpsupport"
}
uci -q set openmptcprouter.$OMR_TRACKER_INTERFACE.state='up'
uci -q set openmptcprouter.$OMR_TRACKER_INTERFACE.lc=$(date +"%s")
}