diff options
| author | Gluzskiy Alexandr <sss@sss.chaoslab.ru> | 2018-06-24 16:48:00 +0300 | 
|---|---|---|
| committer | Gluzskiy Alexandr <sss@sss.chaoslab.ru> | 2018-06-24 16:48:00 +0300 | 
| commit | 9ab7e7279a75c7bc12878275c8211b88ec8b7796 (patch) | |
| tree | f3f4fa5cafe326bf4c810782955ea1e899949d05 /packages/net-libs/tox/files/initd | |
| parent | f4c008270b6e48921c7c2901e7d9952a3a2554a4 (diff) | |
tox-core
Diffstat (limited to 'packages/net-libs/tox/files/initd')
| -rw-r--r-- | packages/net-libs/tox/files/initd | 30 | 
1 files changed, 30 insertions, 0 deletions
diff --git a/packages/net-libs/tox/files/initd b/packages/net-libs/tox/files/initd new file mode 100644 index 0000000..101d329 --- /dev/null +++ b/packages/net-libs/tox/files/initd @@ -0,0 +1,30 @@ +#!/sbin/openrc-run + +PIDDIR=/run/tox-bootstrapd +PIDFILE="${PIDDIR}"/tox-bootstrap.pid + +depend() { +	need net +} + +start() { +	ebegin "Starting tox-dht-bootstrap daemon" + +	checkpath -d -q -o "${TOX_USER}":"${TOX_GROUP}" "${PIDDIR}" + +	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 $? +}  | 
