diff options
author | Francesco Colista <fcolista@alpinelinux.org> | 2019-03-19 15:50:27 +0000 |
---|---|---|
committer | Francesco Colista <fcolista@alpinelinux.org> | 2019-03-19 15:50:32 +0000 |
commit | 39047b22a36ede8e7785960bef21d289949ef66a (patch) | |
tree | 73e17dc5fbcac51ecb4e6dd9b740f9a0db1d3c07 /testing/p910nd/p910nd.initd | |
parent | ef205f803e6fc4748d70bbe2265195c463e2c0b9 (diff) | |
download | aports-39047b22a36ede8e7785960bef21d289949ef66a.tar.bz2 aports-39047b22a36ede8e7785960bef21d289949ef66a.tar.xz |
testing/p910nd: new aport. Fixes 10090
Diffstat (limited to 'testing/p910nd/p910nd.initd')
-rw-r--r-- | testing/p910nd/p910nd.initd | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/testing/p910nd/p910nd.initd b/testing/p910nd/p910nd.initd new file mode 100644 index 0000000000..6378a75f9e --- /dev/null +++ b/testing/p910nd/p910nd.initd @@ -0,0 +1,35 @@ +#!/sbin/openrc-run +# +# Init script for Alpine Linux +# (c) 2019 Francesco Colista <fcolista@alpinelinux.org> +# + +command="/usr/sbin/p910nd" +pidfile="/run/p910nd/p910nd.${P910ND_NUM}.pid" +command_args="${P910ND_OPTS} ${P910ND_NUM}" + +depend() { + need localmount net + after bootmisc +} + +start_pre() { + checkpath -d -m755 /run/p910nd +} + +start() { + ebegin "Starting ${SVCNAME}" + start-stop-daemon \ + --start \ + --pidfile ${pidfile} \ + --exec ${command} \ + -- ${command_args} +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon \ + --stop \ + --pidfile ${pidfile} \ + --exec ${command} +} |