summaryrefslogtreecommitdiff
path: root/net/freenet6/files/freenet6.sh.in
blob: cc23ffa382a4d90940c7c504a0602dca27b61e02 (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
#!/bin/sh
#
# $FreeBSD$
#
# Start or stop the IPv6 tunnel to Freenet6.net
#

case "$1" in
	start)
		echo -n " freenet6"
		if [ -f @@PREFIX@@/etc/tspc.conf ]; then
			@@PREFIX@@/bin/tspc
		fi
		;;

	stop)
		if [ ! -f /var/run/tspc.if ]; then
			echo "TSPC not running"
			exit 64
		fi
		/sbin/ifconfig `cat /var/run/tspc.if` destroy
		;;

	*)
		echo ""
		echo "Usage: `basename $0` { start | stop }"
		echo ""
		exit 64
		;;
esac