Skip to content
This repository has been archived by the owner on Aug 18, 2023. It is now read-only.

statsd_exporter: no way to specify global defaults #11

Closed
urusha opened this issue Apr 2, 2020 · 3 comments
Closed

statsd_exporter: no way to specify global defaults #11

urusha opened this issue Apr 2, 2020 · 3 comments
Assignees

Comments

@urusha
Copy link
Contributor

urusha commented Apr 2, 2020

There is no way to specify global defaults ( https://github.com/prometheus/statsd_exporter#global-defaults ) with prometheus_statsd_exporter_cfg.
We could remove mappings: from https://github.com/mesaguy/ansible-prometheus/blob/master/templates/statsd_exporter.yml.j2 but that would not be backward compatible (although this could be fixed in the template by transforming cfg variable). Or we could add prometheus_statsd_exporter_cfg_defaults to the template.
I'm ready to make a PR if it's needed, please advice what way to choose.

By the way https://github.com/mesaguy/ansible-prometheus/blob/master/docs/statsd_exporter.md doesn't mention that we also need to add extra_opts to use templated config.

prometheus_statsd_exporter_extra_opts:
- "--statsd.mapping-config={{prometheus_etc_dir}}/statsd_exporter.yml"

Instead we see confusing: If no configuration content is defined, a default configuration file is utilized.

@mesaguy
Copy link
Owner

mesaguy commented Apr 16, 2020

Your approach looks good. I have started testing your PRs against the test suite of distros and expect to accept them in the next couple of days. Thanks!

@mesaguy mesaguy self-assigned this Apr 16, 2020
@urusha
Copy link
Contributor Author

urusha commented Apr 16, 2020

Thanks. Just want to mention that vars/software/* in PRs doesn't contain full info. Is there a script for automating it (that uses github api, I guess)? I've just filled it with the last linux amd64 releases to make it work in my case. But I could make additional PR solving this in automated way (or may be it's easier for you to make these changes). Also PRs doesn't add links to exporters and docs to root README.md - just to avoid conflicts.

@mesaguy
Copy link
Owner

mesaguy commented Apr 19, 2020

Your PRs have been accepted and released in v0.12.0. I have created issue #20 to track improving documentation and processes around adding exporters. I have Python code for creating/updating metadata which I need to clean up and release.

@mesaguy mesaguy closed this as completed Apr 19, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants