summaryrefslogtreecommitdiff
blob: c98c7b08205e307bef8b746fa2ab66abe4432547 (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
26
27
28
29
30
31
#!/sbin/openrc-run
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

depend() {
	need net
	after bootmisc
}

start() {
    ebegin "Starting influxdb server"

    start-stop-daemon --start -b \
        --user influxdb:influxdb \
	--pidfile /run/influxdb.pid \
	--make-pidfile \
	--stdout /var/log/influxdb/influxd.log \
	--stderr /var/log/influxdb/influxd.log \
	--exec /usr/bin/influxd -- -config /etc/influxdb/influxdb.conf
    eend $?
}

stop() {
    ebegin "Stopping influxdb server"

    start-stop-daemon --stop \
	--pidfile /run/influxdb.pid \
	--exec /usr/bin/influxd
    eend $?
}