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

Add example on how to update prometheus targets #67

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,21 @@ so this workaround is required.

The `/clients` endpoint will return a list of all registered clients in the format
used by `file_sd_configs`. You could use wget in a cronjob to put it somewhere
file\_sd\_configs can read and then then relabel as needed.
file\_sd\_configs can read and then then relabel as needed. For example:

```
scrape_configs:
- job_name: node
proxy_url: http://proxy:8080/
file_sd_configs:
- files:
- pushprox.json
relabel_configs:
- source_labels: ['__address__']
regex: '(.*)'
replacement: '$1:9100'
target_label: '__address__'
```

## How It Works

Expand Down