aboutsummaryrefslogtreecommitdiffstats
path: root/community/ospd-openvas/ospd-openvas.initd
blob: 0094d29a30d2e54ea15c22c6e690645a9b437917 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/sbin/openrc-run

name="Remotely control an OpenVAS Scanner"
command="/usr/bin/ospd-openvas"
pidfile="/run/ospd/${RC_SVCNAME}.pid"

: ${OSPD_OPENVAS_UNIX_SOCKET:=$(dirname $pidfile)/ospd.sock}
: ${OSPD_OPENVAS_SOCKET_MODE:=0o777}

command_args="${OSPD_OPENVAS_OPTIONS} \
	--unix-socket=${OSPD_OPENVAS_UNIX_SOCKET} \
	--socket-mode=${OSPD_OPENVAS_SOCKET_MODE} \
	--pid-file ${pidfile} \
	--config /etc/openvas/ospd.conf"

depend() {
	after firewall
	need redis
}

start_pre() {
	checkpath --directory "${pidfile%/*}" /var/log/gvm
}