blob: 784074c6566ac445833e05f95d70a8795c5951cc (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
#!/bin/sh
SHORT_NAME="realraumwire"
DESC_NAME="realraum WIRE"
INTERFACE="{{ ws_minet_wired_interface_name }}"
MODULE_NAME="{{ ws_minet_wired_interface_module }}"
. /usr/local/lib/minet/minet_helpers.sh
case "$1" in
start|"")
echo "Connecting with $DESC_NAME"
activate_interface $INTERFACE $MODULE_NAME
ip link set up dev $INTERFACE
ip addr add dev $INTERFACE 89.106.211.60/27
ip route add default via 89.106.211.33
ip -6 addr add dev $INTERFACE 2a02:3e0:4000:1::60/64
ip -6 route add default via 2a02:3e0:4000:1::1
echo "search realraum.at" > /tmp/$SHORT_NAME.resolv
echo "domain realraum.at" >> /tmp/$SHORT_NAME.resolv
echo "nameserver 89.106.211.33" >> /tmp/$SHORT_NAME.resolv
resolvconf -a $INTERFACE < /tmp/$SHORT_NAME.resolv
rm /tmp/$SHORT_NAME.resolv
;;
stop)
echo "Disconnecting from $DESC_NAME"
resolvconf -d $INTERFACE
deactivate_interface $INTERFACE $MODULE_NAME
;;
*)
exit 1
;;
esac
|