Add simple webserver for RPL status
[contiki-2.x.git] / tools / setup-nat-ubuntu
blobaddae148c34ae6fd7fe322732da0c0ba2e2658de
1 #!/bin/sh
3 # Run this script as root ("sudo ./setup-nat-ubuntu"). It has been tested on Ubunru 8.04.
5 /sbin/iptables --table nat --append POSTROUTING --out-interface eth10 -j MASQUERADE
6 /sbin/iptables --append FORWARD --in-interface tun0 -j ACCEPT
7 /sbin/iptables --append FORWARD --in-interface tap0 -j ACCEPT
9 /sbin/sysctl -w net.ipv4.conf.default.forwarding=1
10 /sbin/sysctl -w net.ipv4.conf.all.forwarding=1
12 /sbin/sysctl -w net.ipv4.ip_forward=1
14 echo 1 > /proc/sys/net/ipv4/ip_forward