mirror of
https://github.com/ergochat/ergo.git
synced 2024-11-24 12:59:33 +01:00
distrib: add OpenRC init scripts
Written originally for Gentoo but should work on Alpine and other OpenRC-consuming distros too. Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
parent
a0ad42272d
commit
2619a23458
2
distrib/openrc/ergo.confd
Normal file
2
distrib/openrc/ergo.confd
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
# /etc/conf.d/ergo: config file for /etc/init.d/ergo
|
||||||
|
ERGO_CONFIGFILE="/etc/ergo/ircd.yaml"
|
19
distrib/openrc/ergo.initd
Normal file
19
distrib/openrc/ergo.initd
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
#!/sbin/openrc-run
|
||||||
|
command=/usr/bin/ergo
|
||||||
|
command_args="run --conf ${ERGO_CONFIGFILE:-"/etc/ergo/ircd.yaml"}"
|
||||||
|
command_background=true
|
||||||
|
extra_started_commands="reload"
|
||||||
|
pidfile=/var/run/ergo.pid
|
||||||
|
name="ergo"
|
||||||
|
description="ergo IRC daemon"
|
||||||
|
|
||||||
|
depend() {
|
||||||
|
use dns
|
||||||
|
provide ircd
|
||||||
|
}
|
||||||
|
|
||||||
|
reload() {
|
||||||
|
ebegin "Reloading ${RC_SVCNAME}"
|
||||||
|
start-stop-daemon --signal HUP --pidfile "${pidfile}"
|
||||||
|
eend $?
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user