summaryrefslogtreecommitdiffstats
path: root/retiolum/hosts
diff options
context:
space:
mode:
authorLassulus <Lassulus@googlemail.com>2011-05-25 17:02:11 +0200
committerLassulus <Lassulus@googlemail.com>2011-05-25 17:02:11 +0200
commitf70c72f311a72a0dbcede60889dfd2d40a11f2da (patch)
tree51a37e0338ab5f13ca346ce50b07fe1e6f832574 /retiolum/hosts
parent0733a1fd5083379c967a110862bb327153ebebb1 (diff)
added rc.d retiolum file
Diffstat (limited to 'retiolum/hosts')
-rwxr-xr-xretiolum/hosts/.scripts/tinc_multicast/retiolum34
1 files changed, 34 insertions, 0 deletions
diff --git a/retiolum/hosts/.scripts/tinc_multicast/retiolum b/retiolum/hosts/.scripts/tinc_multicast/retiolum
new file mode 100755
index 00000000..f506a1b0
--- /dev/null
+++ b/retiolum/hosts/.scripts/tinc_multicast/retiolum
@@ -0,0 +1,34 @@
+#!/bin/bash
+
+. /etc/rc.conf
+. /etc/rc.d/functions
+
+TINCNAME='retiolum'
+case "$1" in
+ start)
+ stat_busy "Starting retiolum Daemon"
+ success=0
+ /home/death/git/retiolum/.scripts/tinc_multicast/retiolum.py -n retiolum -T &
+ sleep 2
+ if [ $success -eq 0 ]; then
+ add_daemon retiolum
+ stat_done
+ else
+ stat_fail
+ fi
+ ;;
+ stop)
+ stat_busy "Stopping retiolum Daemon"
+ kill `cat /var/lock/retiolum.retiolum`
+ rm_daemon tincd
+ stat_done
+ ;;
+ restart)
+ $0 stop
+ sleep 4
+ $0 start
+ ;;
+ *)
+ echo "usage $0 {startĀ¦stopĀ¦restart}"
+esac
+exit 0