Prometheus CommonStatus blackbox exporter
Docker image with the exporter is automatically built from master branch by CI and available at https://quay.io/repository/gips0n/cs_exporter
To pull the image run:
docker pull quay.io/gips0n/cs_exporter
To configure exporter use environment variables:
- CS_LOG_LEVEL - set log level, supported values: DEBUG, INFO, WARN, ERROR; default: INFO
- CS_CONNECTION_TIMEOUT - set connection timeout; default: 8 seconds
- CS_PORT - set port on which the exporter will run; default: 9259
Connection timeout occurs when the exporter sends requests to backends (from which it scapes metrics) and the backend takes too long to respond to a request. The value is controlled by:
- "X-Prometheus-Scrape-Timeout-Seconds" header in probe-request - per probe, has the highest priority, configured on prometheus server side
- CS_CONNECTION_TIMEOUT environment variable - default for all probes
- Default value of CS_CONNECTION_TIMEOUT - default for all probes
Use make
or make run
or docker-compose up --build
to run local development environment which consists of local prometheus server, commonstatus_exporter and testservice which is hosting sample data.
Run docker-compose down --volumes
to remove the containers and docker volume
On the prometheus target page you should see 3 targets: prometheus, exporter, testservice and information about the last scrape and scrape errors. On the graph page you can execute queries to retrieve metrics.