diff options
author | Kacper Kowalik <xarthisius@gentoo.org> | 2010-06-19 20:12:41 +0000 |
---|---|---|
committer | Kacper Kowalik <xarthisius@gentoo.org> | 2010-06-19 20:12:41 +0000 |
commit | a6dee94883caf8176b4b087506802456203cac0d (patch) | |
tree | db525a3c4c57f8a6459f8ae5ed566d020888d2c6 /sys-cluster/csync2/files | |
parent | Version bump. (diff) | |
download | gentoo-2-a6dee94883caf8176b4b087506802456203cac0d.tar.gz gentoo-2-a6dee94883caf8176b4b087506802456203cac0d.tar.bz2 gentoo-2-a6dee94883caf8176b4b087506802456203cac0d.zip |
Adding init script. Thanks to Ultrabug <ultrabug@ultrabug.net>
(Portage version: 2.1.8.3/cvs/Linux x86_64)
Diffstat (limited to 'sys-cluster/csync2/files')
-rwxr-xr-x | sys-cluster/csync2/files/csync2.initd | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/sys-cluster/csync2/files/csync2.initd b/sys-cluster/csync2/files/csync2.initd new file mode 100755 index 000000000000..55537be94a66 --- /dev/null +++ b/sys-cluster/csync2/files/csync2.initd @@ -0,0 +1,26 @@ +#!/sbin/runscript +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-cluster/csync2/files/csync2.initd,v 1.1 2010/06/19 20:12:41 xarthisius Exp $ + +PIDFILE=/var/run/csync2.pid +BINARY=/usr/sbin/csync2 + +start() { + ebegin "Starting csync2" + start-stop-daemon --start --pidfile "${PIDFILE}" -m -x ${BINARY} -b -- -ii + eend $? +} + +stop() { + ebegin "Stopping csync2" + start-stop-daemon --stop --pidfile "${PIDFILE}" + eend $? +} + +restart() { + ebegin "Restarting csync2" + svc_stop + svc_start + eend $? +} |