summaryrefslogtreecommitdiff
path: root/net-analyzer/openvas-scanner/files/redis-openvas.initd
blob: 5c50d29dae6a043351a6dae1ea007109df937a68 (plain)
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
#!/sbin/openrc-run
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

: ${REDIS_DIR:=/var/lib/gvm/redis}
: ${REDIS_CONF:=/etc/gvm/redis-openvas.conf}
: ${REDIS_OPTS:="${REDIS_CONF}"}
: ${REDIS_USER:=gvm}
: ${REDIS_GROUP:=gvm}
: ${REDIS_TIMEOUT:=30}

# https://bugs.gentoo.org/631002#c10
# Force '--daemonize no' to override the config file
command="/usr/sbin/redis-server"
command_args="${REDIS_OPTS} --daemonize no"
command_background="true"
command_user="${REDIS_USER}:${REDIS_GROUP}"
pidfile="/run/${RC_SVCNAME}/redis-server.pid"
retry="${REDIS_TIMEOUT}"
start_stop_daemon_args="--chdir \"${REDIS_DIR}\""

depend() {
	use localmount logger
	after keepalived
}