Initial commit
This commit is contained in:
commit
09229be6c0
38
Makefile
Normal file
38
Makefile
Normal file
@ -0,0 +1,38 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PORTNAME= graphite_exporter
|
||||
PORTVERSION= 0.8.0
|
||||
DISTVERSIONPREFIX=v
|
||||
CATEGORIES= sysutils
|
||||
|
||||
MAINTAINER= yo@nosd.in
|
||||
COMMENT= Accepts Graphite metrics and exports them as Prometheus metrics
|
||||
|
||||
LICENSE= APACHE20
|
||||
LICENSE_FILE= ${WRKSRC}/LICENSE
|
||||
|
||||
USES= go:modules
|
||||
USE_GITHUB= yes
|
||||
GH_ACCOUNT= prometheus
|
||||
GH_PROJECT= graphite_exporter
|
||||
|
||||
USERS= prometheus
|
||||
GROUPS= prometheus
|
||||
|
||||
GH_TUPLE= prometheus:client_golang:v1.6.0:client_golang/vendor/github.com/prometheus/client_golang
|
||||
GH_TUPLE+= go-kit:kit:v0.10.0:kit/vendor/github.com/go-kit/kit
|
||||
GH_TUPLE+= prometheus:common:v0.10.0:common/vendor/github.com/prometheus/common
|
||||
GH_TUPLE+= prometheus:statsd_exporter:v0.16.0:statsd_exporter/vendor/github.com/prometheus/statsd_exporter
|
||||
GH_TUPLE+= alecthomas:kingpin:v2.2.6:kingpin/vendor/gopkg.in/alecthomas/kingpin
|
||||
|
||||
GO_PKGNAME= github.com/${GH_ACCOUNT}/${GH_PROJECT}
|
||||
|
||||
USE_RC_SUBR= graphite_exporter
|
||||
|
||||
PLIST_FILES= bin/graphite_exporter
|
||||
PLIST_FILES+= etc/rc.d/graphite_exporter
|
||||
|
||||
pre-test:
|
||||
${SETENV} GOPATH="${WRKDIR}"
|
||||
|
||||
.include <bsd.port.mk>
|
13
distinfo
Normal file
13
distinfo
Normal file
@ -0,0 +1,13 @@
|
||||
TIMESTAMP = 1592054524
|
||||
SHA256 (prometheus-graphite_exporter-v0.8.0_GH0.tar.gz) = fed8769d8760d69f04724afab0af879e61a8bc159b1147b9fdaf41641655fecf
|
||||
SIZE (prometheus-graphite_exporter-v0.8.0_GH0.tar.gz) = 1694157
|
||||
SHA256 (prometheus-client_golang-v1.6.0_GH0.tar.gz) = e255f632b7223f794e0f60d99976535c16153cc00fadf39ee87fd9f678d6a32c
|
||||
SIZE (prometheus-client_golang-v1.6.0_GH0.tar.gz) = 157355
|
||||
SHA256 (go-kit-kit-v0.10.0_GH0.tar.gz) = c0fac2e37b981e4c18e4f210b92e1393bd59dadd7c7fc043ec46d1c9834eba85
|
||||
SIZE (go-kit-kit-v0.10.0_GH0.tar.gz) = 274801
|
||||
SHA256 (prometheus-common-v0.10.0_GH0.tar.gz) = 349381082ea8e66637c2d2475f1ae0e74ca04a7b91eb3b96817c261b87668fd3
|
||||
SIZE (prometheus-common-v0.10.0_GH0.tar.gz) = 107763
|
||||
SHA256 (prometheus-statsd_exporter-v0.16.0_GH0.tar.gz) = 37b737842f0be2fc3222604ea335245c0ec1a99dd3541e15366f56cff2c3724a
|
||||
SIZE (prometheus-statsd_exporter-v0.16.0_GH0.tar.gz) = 1763436
|
||||
SHA256 (alecthomas-kingpin-v2.2.6_GH0.tar.gz) = 4624eae43489de8a71ea60efaf6744c581b6bd62909f7514c484c1ea0efaba5a
|
||||
SIZE (alecthomas-kingpin-v2.2.6_GH0.tar.gz) = 44383
|
34
files/graphite_exporter.in
Normal file
34
files/graphite_exporter.in
Normal file
@ -0,0 +1,34 @@
|
||||
#!/bin/sh
|
||||
|
||||
# $FreeBSD: head/net/graphite_exporter/files/graphite_exporter.in 529909 2020-03-30 19:18:03Z decke $
|
||||
#
|
||||
# PROVIDE: graphite_exporter
|
||||
# REQUIRE: DAEMON
|
||||
# KEYWORD: shutdown
|
||||
#
|
||||
# graphite_exporter_enable (bool): Set to "YES" to enable graphite_exporter.
|
||||
# (default: "NO")
|
||||
#
|
||||
# graphite_exporter_logfile (str): File where to write log entries.
|
||||
# (default: "/var/log/graphite_exporter.log")
|
||||
#
|
||||
# graphite_exporter_user (str): User to run graphite_exporter process
|
||||
# (default: "prometheus")
|
||||
|
||||
. /etc/rc.subr
|
||||
|
||||
name=graphite_exporter
|
||||
rcvar=graphite_exporter_enable
|
||||
|
||||
load_rc_config $name
|
||||
|
||||
: ${graphite_exporter_enable="NO"}
|
||||
: ${graphite_exporter_logfile="/var/log/maillog"}
|
||||
: ${graphite_exporter_pidfile:="/var/run/graphite_exporter.pid"}
|
||||
: ${graphite_exporter_user:="prometheus"}
|
||||
|
||||
command="/usr/local/bin/graphite_exporter"
|
||||
command_args="> \${graphite_exporter_logfile} 2>&1"
|
||||
start_cmd="/usr/sbin/daemon -u ${graphite_exporter_user} ${command} ${command_args}"
|
||||
|
||||
run_rc_command "$1"
|
Loading…
Reference in New Issue
Block a user