projects/aports·blob master · refs

29 lines · 566 B

1#!/sbin/openrc-run
2
3# fallback values for /etc/conf.d/webhookd
4: ${command_user:=webhookd:webhookd}
5: ${directory:=/var/lib/webhookd}
6: ${logdir:=/var/log/webhookd}
7
8name=webhookd
9description="webhookd daemon"
10command="/usr/bin/webhookd"
11command_background=true
12pidfile="/run/$name.pid"
13
14depend() {
15 need net
16 use dns logger
17}
18
19start_pre() {
20 checkpath -d -o "$command_user" "$directory" "$logdir"
21
22 if [ -n "$output_log" ]; then
23 checkpath -f -o "$command_user" "$output_log"
24 fi
25
26 if [ -n "$error_log" ]; then
27 checkpath -f -o "$command_user" "$error_log"
28 fi
29}