wok-stable annotate mirror-tools/stuff/usr/share/mirror-host/install @ rev 7219
Fixed talloc and talloc-dev. Added soft links for libtalloc.so.2.0.1 and libtalloc-compat1.so.2.0.1 so there link to samba.
author | Christopher Rogers <slaxemulator@gmail.com> |
---|---|
date | Wed Nov 10 23:53:15 2010 +0000 (2010-11-10) |
parents | |
children |
rev | line source |
---|---|
pascal@5974 | 1 #!/bin/sh |
pascal@5974 | 2 |
pascal@5974 | 3 grep -qs lguest-slitaz /etc/inittab || { |
pascal@5974 | 4 sed -i 's|^tty1::|tty16::respawn:/boot/lguest-slitaz tty16 /boot/guests/mirror.slitaz.org 192.168.0.1\n&|' /etc/inittab |
pascal@5974 | 5 cat >> /etc/init.d/local.sh <<EOT |
pascal@5974 | 6 . /etc/network.conf |
pascal@5974 | 7 iptables -t nat -A POSTROUTING -o $INTERFACE -j MASQUERADE |
pascal@5974 | 8 for port in 22 873 ; do |
pascal@5974 | 9 iptables -t nat -A PREROUTING -i $INTERFACE --dport $port \ |
pascal@5974 | 10 -j DNAT --to-destination 192.168.0.6:$port |
pascal@5974 | 11 done |
pascal@5974 | 12 for port in 80 443 ; do |
pascal@5974 | 13 iptables -A INPUT -p tcp -m tcp --dport $port -j ACCEPT |
pascal@5974 | 14 done |
pascal@5974 | 15 for iface in tap+ ; do |
pascal@5974 | 16 iptables -A INPUT -i $iface -j ACCEPT |
pascal@5974 | 17 iptables -A OUTPUT -o $iface -j ACCEPT |
pascal@5974 | 18 iptables -A FORWARD -i $iface -m state \ |
pascal@5974 | 19 --state NEW,RELATED,ESTABLISHED,UNTRACKED -j ACCEPT |
pascal@5974 | 20 iptables -A FORWARD -o $iface -m state \ |
pascal@5974 | 21 --state NEW,RELATED,ESTABLISHED,UNTRACKED -j ACCEPT |
pascal@5974 | 22 done |
pascal@5974 | 23 echo "1" > /proc/sys/net/ipv4/ip_forward |
pascal@5974 | 24 EOT |
pascal@5974 | 25 } |