mirror of
https://dev.iopsys.eu/feed/iopsys.git
synced 2025-12-10 07:44:50 +01:00
netmode: add support for disabling legacy netmode tools
This commit is contained in:
parent
7ba08eb358
commit
66da522ebb
2 changed files with 11 additions and 5 deletions
|
|
@ -3,3 +3,7 @@ config mode 'setup'
|
|||
option detail ''
|
||||
option curmode 'routed'
|
||||
|
||||
config tools 'tools'
|
||||
option wificontrol 1
|
||||
option arp_discovery 1
|
||||
|
||||
|
|
|
|||
|
|
@ -421,17 +421,19 @@ populate_netmodes() {
|
|||
}
|
||||
|
||||
start_netmode_tools() {
|
||||
local curmode repeaterready
|
||||
local curmode repeaterready wificontrol discover
|
||||
|
||||
killall -9 wificontrol >/dev/null 2>&1
|
||||
killall -9 netmode-discover >/dev/null 2>&1
|
||||
|
||||
config_load netmode
|
||||
config_get_bool repeaterready setup repeaterready 0
|
||||
config_get_bool wificontrol tools wificontrol 1
|
||||
config_get_bool arp_discovery tools arp_discovery 1
|
||||
|
||||
[ $repeaterready -eq 1 ] && {
|
||||
/sbin/netmode-discover &
|
||||
/sbin/wificontrol --repeater &
|
||||
[ $arp_discovery -eq 1 ] && /sbin/netmode-discover &
|
||||
[ $wificontrol -eq 1 ] && /sbin/wificontrol --repeater &
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -439,8 +441,8 @@ start_netmode_tools() {
|
|||
|
||||
case "$curmode" in
|
||||
repeater*)
|
||||
/sbin/netmode-discover &
|
||||
/sbin/wificontrol --repeater &
|
||||
[ $arp_discovery -eq 1 ] && /sbin/netmode-discover &
|
||||
[ $wificontrol -eq 1 ] && /sbin/wificontrol --repeater &
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue