inteno-netmodes: switch to extender mode if behind non inteno priva IP

This commit is contained in:
Sukru Senli 2017-06-14 17:44:12 +02:00
parent 05ee1c51ad
commit 724ee411fc

View file

@ -66,13 +66,12 @@ switch_mode() {
wifi reload nodat
ubus call router.network reload
ubus call leds set '{"state" : "normal"}'
}
test_ip() {
if [ -n "$(echo $ip | grep -E '^(192\.168|10\.|172\.1[6789]\.|172\.2[0-9]\.|172\.3[01]\.)')" ]; then
# private IP
#switch_mode
switch_mode
set_disabled 1
else
# public IP