blob: 8d984ccc7ce5f28603af90763425165fa6ac0549 (
plain)
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
34
35
36
37
|
#!/sbin/runscript
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-nntp/nzbget/files/nzbget.initd,v 1.3 2011/12/25 07:42:35 radhermit Exp $
extra_started_commands="pause unpause"
depend() {
need net
}
start() {
ebegin "Starting nzbget"
start-stop-daemon --quiet --start --user "${NZBGET_USER}" \
--group "${NZBGET_GROUP}" --exec /usr/bin/nzbget -- \
--configfile "${NZBGET_CONFIGFILE}" --daemon \
${NZBGET_OPTS}
eend $?
}
stop() {
ebegin "Stopping nzbget"
/usr/bin/nzbget --configfile "${NZBGET_CONFIGFILE}" --quit >/dev/null
eend $?
}
pause() {
ebegin "Pausing nzbget"
/usr/bin/nzbget --configfile "${NZBGET_CONFIGFILE}" --pause >/dev/null
eend $?
}
unpause() {
ebegin "Unpausing nzbget"
/usr/bin/nzbget --configfile "${NZBGET_CONFIGFILE}" --unpause >/dev/null
eend $?
}
|