~dricottone/huttese-apk

ref: 1c6282ce7d58442c9d88ba0d230c4a3f39d48d8e huttese-apk/sr.ht/soju/soju.initd -rw-r--r-- 558 bytes
1c6282ce — Drew DeVault py3-kombu: upgrade to 5.2.1 3 years ago
                                                                                
4f9cef53 Simon Ser
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
#!/sbin/openrc-run
supervisor=supervise-daemon

name="soju"
description="User-friendly IRC bouncer"

command=/usr/bin/soju
command_user=soju:soju
directory="/var/lib/$RC_SVCNAME"

extra_started_commands="reload"
description_reload="Reload TLS certificate"

depend() {
	need net localmount
	after firewall
}

start_pre() {
	checkpath --directory --owner $command_user --mode 0775 "$directory"
	[ -n "$error_log" ] && checkpath -f -o $command_user "$error_log"
}

reload() {
	ebegin "Reloading TLS certificate"
	$supervisor $RC_SVCNAME --signal HUP
	eend $?
}