prometheus-pusher

command module
v0.0.0-...-1262687 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 29, 2016 License: Apache-2.0 Imports: 12 Imported by: 0

README

prometheus-pusher

prometheus-pusher aggregates Prometheus metrics from different endpoints and push them to pushgateway

Installation

$ go get github.com/ShowMax/prometheus-pusher

Usage

  -config string
    	Config file or directory. If directory is specified then all files in the directory will be loaded. (default "/etc/prometheus-pusher/conf.d")
  -dummy
      Do not post the metrics, just print them to stdout

Example configuration

[config]
pushgateway_url = "http://localhost:9091" # Default
push_interval = 60                        # Default (in seconds)

[metric_name]
host = "localhost" # Default
path = "/metrics"  # Default
ssl = false        # Default
port = 9111

[second_metric]
port = 9112

Logging

prometheus-pusher uses logxi for logging.

The format may be set via LOGXI_FORMAT environment variable. Valid values are "happy", "text", "JSON", "LTSV".

By default logxi logs entries whose level is LevelWarn or above when using a terminal.

To change the level, use LOGXI environment variable. Valid values are "DBG", "INF", "WRN", "ERR", "FTL".

LOGXI=* prometheus-pusher
# the above statement is equivalent to this
LOGXI=*=DBG prometheus-pusher
# now using json format instead
LOGXI_FORMAT=JSON prometheus-pusher

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL