diff options
author | William Hubbs <williamh@gentoo.org> | 2020-03-15 18:07:27 -0500 |
---|---|---|
committer | William Hubbs <williamh@gentoo.org> | 2020-03-15 18:11:01 -0500 |
commit | 22ae5af892bcbe16a39954537a55b5940f8dcd81 (patch) | |
tree | 3034e3a0275b6e7505431a953c6e2aebfcd18a2a /app-metrics/node_exporter/files | |
parent | sys-kernel/git-sources: Linux patch 5.6-rc6 (diff) | |
download | gentoo-22ae5af892bcbe16a39954537a55b5940f8dcd81.tar.gz gentoo-22ae5af892bcbe16a39954537a55b5940f8dcd81.tar.bz2 gentoo-22ae5af892bcbe16a39954537a55b5940f8dcd81.zip |
app-metrics/node_exporter: revbump for install location and go migration
Signed-off-by: William Hubbs <williamh@gentoo.org>
Diffstat (limited to 'app-metrics/node_exporter/files')
-rw-r--r-- | app-metrics/node_exporter/files/node_exporter.initd | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/app-metrics/node_exporter/files/node_exporter.initd b/app-metrics/node_exporter/files/node_exporter.initd new file mode 100644 index 000000000000..3ccddf757a89 --- /dev/null +++ b/app-metrics/node_exporter/files/node_exporter.initd @@ -0,0 +1,23 @@ +#!/sbin/openrc-run +# Copyright 2016-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +description="Prometheus machine metrics exporter" +pidfile=${pidfile:-"/run/${RC_SVCNAME}.pid"} +user=${user:-${RC_SVCNAME}} +group=${group:-${RC_SVCNAME}} + +command="/usr/sbin/node_exporter" +command_args="${command_args:---collector.textfile.directory=/var/lib/node_exporter/}" +command_background="true" +start_stop_daemon_args="--user ${user} --group ${group} \ + --stdout /var/log/node_exporter/${RC_SVCNAME}.log \ + --stderr /var/log/node_exporter/${RC_SVCNAME}.log" + +depend() { + after net +} + +start_pre() { + checkpath -q -d -m 0755 -o ${user}:${group} /var/log/node_exporter +} |