blob: b83ca843dd62d5bdf1c3f2937d851433abd9e0eb (
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
# Copyright 1999-2026 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
: ${VNSTATD_USER:=vnstat}
: ${VNSTATD_CONFIGFILE:=/etc/vnstat.conf}
name="vnStat daemon"
description="vnstatd updates vnStat databases"
command="/usr/sbin/vnstatd"
command_args="${VNSTATD_OPTS} --nodaemon --config ${VNSTATD_CONFIGFILE}"
command_background=true
command_user="${VNSTATD_USER}"
pidfile="/run/${RC_SVCNAME}.pid"
required_files="${VNSTATD_CONFIGFILE}"
extra_started_commands="reload"
reload() {
ebegin "Reloading ${name} configuration"
start-stop-daemon --signal HUP --pidfile "${pidfile}"
eend $?
}
|