blob: b5ef4cd4db41a597cc71b30b62319896d9d6f036 (
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
|
#!/sbin/openrc-run
PIDDIR=/run/tox-bootstrapd
PIDFILE="${PIDDIR}"/tox-bootstrapd.pid
KEYSDIR=/var/lib/tox-bootstrapd
TOX_USER=tox
TOX_GROUP=tox
depend() {
need net
}
start() {
ebegin "Starting tox-dht-bootstrap daemon"
checkpath -d -q -o "${TOX_USER}":"${TOX_GROUP}" "${PIDDIR}"
checkpath -d -q -o "${TOX_USER}":"${TOX_GROUP}" "${KEYSDIR}"
set rc_ulimts 4096
start-stop-daemon --start \
--pidfile "${PIDFILE}" \
--user="${TOX_USER}" --group="${TOX_GROUP}" \
--exec /usr/bin/tox-bootstrapd -- --config /etc/tox-bootstrapd.conf
eend $?
}
stop() {
ebegin "Stopping tox-dht-bootstrap daemon"
start-stop-daemon --stop \
--pidfile "${PIDFILE}"
eend $?
}
|