summaryrefslogtreecommitdiff
path: root/net-p2p/syncthing/files/rc/init
diff options
context:
space:
mode:
authorGluzskiy Alexandr <sss123next@list.ru>2015-12-29 10:36:32 +0300
committerGluzskiy Alexandr <sss123next@list.ru>2015-12-29 10:36:32 +0300
commit22b6e21eb98f1cbac3ac71e58acf19d4a2d9eedf (patch)
tree1f02090f0df87ce7116b6c27b0d2cbc259878d96 /net-p2p/syncthing/files/rc/init
parent79c5a71569059b40c622948fb41ee48a9daf1069 (diff)
syncthing from nightmare repo
Diffstat (limited to 'net-p2p/syncthing/files/rc/init')
-rw-r--r--net-p2p/syncthing/files/rc/init22
1 files changed, 22 insertions, 0 deletions
diff --git a/net-p2p/syncthing/files/rc/init b/net-p2p/syncthing/files/rc/init
new file mode 100644
index 0000000..029e567
--- /dev/null
+++ b/net-p2p/syncthing/files/rc/init
@@ -0,0 +1,22 @@
+#!/sbin/runscript
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+depend() {
+ need net
+}
+
+start() {
+ ebegin "Starting syncthing"
+ start-stop-daemon --start --make-pidfile --pidfile /var/run/syncthing.pid \
+ --background --user ${SYNCTHING_USER} --name syncthing \
+ --exec /usr/bin/syncthing -- -gui-address=${SYNCTHING_ADDRESS} ${SYNCTHING_ARGS}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping syncthing"
+ start-stop-daemon --stop --pidfile /var/run/syncthing.pid --user ${SYNCTHING_USER}
+ eend $?
+} \ No newline at end of file