summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xImmaeEu-down6
-rwxr-xr-xImmaeEu-up6
2 files changed, 8 insertions, 4 deletions
diff --git a/ImmaeEu-down b/ImmaeEu-down
index 8459778..638933f 100755
--- a/ImmaeEu-down
+++ b/ImmaeEu-down
@@ -4,9 +4,11 @@
4[ -e /tmp/tinc_$NETNAME ] && . /tmp/tinc_$NETNAME 4[ -e /tmp/tinc_$NETNAME ] && . /tmp/tinc_$NETNAME
5[ -e /run/tinc_$NETNAME.vars ] && . /run/tinc_$NETNAME.vars 5[ -e /run/tinc_$NETNAME.vars ] && . /run/tinc_$NETNAME.vars
6rm -f /tmp/tinc_$NETNAME /run/tinc_$NETNAME.vars 6rm -f /tmp/tinc_$NETNAME /run/tinc_$NETNAME.vars
7[ -n "$GWIP" ] && ip -6 route del default via $GWIP 7[ -n "$GWIP" ] && ip -6 route del default via $GWIP table 655
8for MYIP in $MYIPS; do 8for MYIP in $MYIPS; do
9 ip -6 addr del $MYIP/96 dev $INTERFACE 9 ip -6 addr del $MYIP/80 dev $INTERFACE
10 ip -6 rule del from $MYIP/80 table 655
11 ip -6 rule del to $MYIP/80 table 655
10done 12done
11ip -6 link set $INTERFACE down 13ip -6 link set $INTERFACE down
12 14
diff --git a/ImmaeEu-up b/ImmaeEu-up
index c2dc93a..a3784aa 100755
--- a/ImmaeEu-up
+++ b/ImmaeEu-up
@@ -18,7 +18,9 @@ rm -f /run/tinc_$NETNAME.vars
18echo -e "MYIPS=\"$MYIPS\"\nGWIP=\"$GWIP\"" > /run/tinc_$NETNAME.vars 18echo -e "MYIPS=\"$MYIPS\"\nGWIP=\"$GWIP\"" > /run/tinc_$NETNAME.vars
19ip -6 link set $INTERFACE up mtu 1280 19ip -6 link set $INTERFACE up mtu 1280
20for MYIP in $MYIPS; do 20for MYIP in $MYIPS; do
21 ip -6 addr add $MYIP/96 dev $INTERFACE 21 ip -6 addr add $MYIP/80 dev $INTERFACE
22 ip -6 rule add from $MYIP/80 table 655
23 ip -6 rule add to $MYIP/80 table 655
22done 24done
23ip -6 route add default via $GWIP 25ip -6 route add default via $GWIP dev $INTERFACE table 655
24(cd /etc/tinc/$NETNAME/hosts && git pull -q origin master) || true 26(cd /etc/tinc/$NETNAME/hosts && git pull -q origin master) || true