Update pi scripts

This commit is contained in:
2016-11-26 22:05:31 +01:00
committed by jbnadal
parent 1969b9b4e4
commit 88ac35c1c9
5 changed files with 12 additions and 7 deletions

8
bsp/scripts/bridge_eth_wifi.sh Executable file
View File

@@ -0,0 +1,8 @@
#!/bin/bash
sudo iptables -t nat -A POSTROUTING -o wlp2s0 -s 192.168.2.0/24 -j MASQUERADE
sudo bash -c "echo 1 > /proc/sys/net/ipv4/ip_forward"
sudo kill -9 dnsmasq
sleep 1
sudo dnsmasq -d -i eno1 -I lo --dhcp-range="192.168.2.100,192.168.2.150,12h" --dhcp-option="1,255.255.255.0" --dhcp-option="3,192.168.2.1"
# -d to keep forground