Add widget config from community profile to meshwizard
[project/luci.git] / contrib / package / meshwizard / files / usr / bin / meshwizard / helpers / setup_lan_static.sh
1 #!/bin/sh
2 # Setup static interface settings for lan if lan is not an olsr interface
3
4 [ ! "$(uci -q get network.lan)" == "interface" ] && exit
5
6 . /lib/functions.sh
7 . $dir/functions.sh
8
9 uci batch << EOF
10 set network.lan.proto='$lan_proto'
11 set network.lan.ipaddr='$lan_ip4addr'
12 set network.lan.netmask='$lan_netmask'
13 EOF
14
15 uci_commitverbose "Setup static ip settings for lan" network
16
17 uci delete meshwizard.lan && uci commit meshwizard