Public | Automated Build

Last pushed: 8 months ago
Short Description
HAProxy to Graphite Container
Full Description

haproxy-to-graphite

This container will connect to any accessible HAProxy server which is running stats, by pulling the CSV version of the data.

This data will be sent to a Graphite server. Only columns with int data will be passed along, and any columns with no data will default to 0.

Start a haproxy-to-graphite instance

$ docker run -e GRAPHITE_REPORTED_HOSTNAME=testing123 -e GRAPHITE_HOST=127.0.0.1 -e GRAPHITE_PORT=2003 -e HAPROXY_CSV_ENDPOINT="http://127.0.0.1:8080/;csv;norefresh" -e HAPROXY_USERNAME=admin -e HAPROXY_PASSWORD=admin jngom/haproxy-to-graphite:tag

Graphite Output Format

All data will be output in the following format:

haproxy.GRAPHITE_REPORTED_HOSTNAME.pxname.svname.column

For example:

haproxy.testing123.servers.this_server.scur

Environment Variables

There are 7 environment variables which are required to run this container:

GRAPHITE_REPORTED_HOSTNAME

This is the hostname used in the Graphite output.

GRAPHITE_HOST

This is the hostname or IP address of the Graphite server.

GRAPHITE_PORT

This is the port of the Graphite server.

HAPROXY_CSV_ENDPOINT

This is the full url to the CSV endpoint for your HAProxy stats page. For instance, if your HAProxy server is set up at 127.0.0.1 at port 8080, without a specific page, your endpoint should look like this:

http://127.0.0.1:8080/;csv;norefresh

HAPROXY_USERNAME

This is the username for the stats page of the HAProxy server.

HAPROXY_PASSWORD

This is the password for the stats page of the HAProxy server.

There are also 2 optional variable to control the minimum logging level:

MINIMUM_LOGGING_LEVEL

Sets the minimum log level to write to STDOUT.

  • CRITICAL
  • ERROR
  • WARNING
  • INFO (default)
  • DEBUG

LOOP_INTERVAL

The number of seconds to wait before collecting and sending data again. This is 5 by default.

Docker Pull Command
Owner
jngom
Source Repository