Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prometheus plugin: support passing bearer_token directly #3481

Closed
quantonganh opened this issue Nov 17, 2017 · 1 comment
Closed

Prometheus plugin: support passing bearer_token directly #3481

quantonganh opened this issue Nov 17, 2017 · 1 comment
Assignees
Labels
area/prometheus feature request Requests for new plugin and for new features to existing plugins
Milestone

Comments

@quantonganh
Copy link

Feature Request

Opening a feature request kicks off a discussion.

Proposal:

Current behavior:

https://github.com/influxdata/telegraf/tree/master/plugins/inputs/prometheus

only support to pass bearer token as a path to file:

## Use bearer token for authorization
  # bearer_token = /path/to/bearer/token

Desired behavior:

It should be supported to pass token directly and rename bearer_token to bearer_token_file. Then it will be consistent with https://prometheus.io/docs/prometheus/latest/configuration/configuration/

Use case: [Why is this important (helps with prioritizing requests)]

We are using it for Grafana metrics. After generating the token, no need to copy it to a file.

@danielnelson
Copy link
Contributor

Let's do the prometheus parser #4414 and then this can be done by setting headers in the http input.

@danielnelson danielnelson added area/prometheus feature request Requests for new plugin and for new features to existing plugins labels Nov 12, 2018
@danielnelson danielnelson added this to the 1.10.0 milestone Nov 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/prometheus feature request Requests for new plugin and for new features to existing plugins
Projects
None yet
Development

No branches or pull requests

3 participants