openwrt/viirb monitor: add to lan list
This commit is contained in:
parent
08163641c1
commit
26a5b6e476
1 changed files with 13 additions and 1 deletions
|
@ -22,7 +22,7 @@ cat ~/.ssh/id_rsa.pub | ssh root@${address} "cat > /etc/dropbear/authorized_keys
|
|||
|
||||
cat <<EOF | ssh -t "root@${address}"
|
||||
set -x
|
||||
opkg update
|
||||
# opkg update
|
||||
|
||||
# add jool + bird2 + tcpdump
|
||||
# opkg install jool-tools-netfilter bird2 bird2c tcpdump tmux atop nload
|
||||
|
@ -67,6 +67,16 @@ uci set network.wwan=interface
|
|||
uci set network.wwan.proto=dhcpv6
|
||||
uci set network.wwan.device=phy0-sta0
|
||||
|
||||
# Add wwan to lan zone, if it is not in there already
|
||||
is_in=""
|
||||
for net in \$(uci get firewall.@zone[0].network); do
|
||||
echo \$net | grep ^wwan\$ && is_in=yes && break
|
||||
done
|
||||
|
||||
if [ -z "\$is_in" ]; then
|
||||
uci add_list firewall.@zone[0].network="wwan"
|
||||
fi
|
||||
|
||||
# Create wireless entry for wifi
|
||||
uci set wireless.wifinet1=wifi-iface
|
||||
uci set wireless.wifinet1.device='radio0'
|
||||
|
@ -82,6 +92,8 @@ uci commit
|
|||
|
||||
printf "${root_password}\n${root_password}\n" | passwd
|
||||
|
||||
# Apply all changes
|
||||
reboot
|
||||
|
||||
EOF
|
||||
|
||||
|
|
Loading…
Reference in a new issue