prometheus-configs-provider

command module
v0.1.0-rc.1 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2024 License: MIT Imports: 16 Imported by: 0

README

[!NOTE] The repository has been renamed from prometheus-configs-provider to prometheus-config-provider.

About

This is a simple tool that reads the Docker API and generates Prometheus scrape configs for all Docker configs that have the io.prometheus.scrape_config label set to true.

Usage

usage: prometheus-configs-provider [<flags>]

Flags:
  --[no-]help           Show context-sensitive help (also try --help-long and --help-man).
  --output-dir="/etc/prometheus/configs"  
                        directory for the configs
  --output-ext="yaml"   extension for the configs
  --prometheus-scrape-config-label="io.prometheus.scrape_config"  
                        label to identify prometheus scrape configs
  --[no-]version        Prints current version.
  --[no-]short-version  Print just the version number.

Example

# docker-stack.yml

configs:
  example-scrape-config:
    file: ./example-scrape-config.yaml
    labels:
      - "io.prometheus.scrape_config=true"

With the help of the prometheus-operator/prometheus-operator/tree/main/cmd/prometheus-config-reloader tool, we can automatically reload the Prometheus configuration when the Docker configs are create/update/remove.

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