https://github.com/lhns/prometheus-bash-exporter
Prometheus metric exporter that executes a bash script on every scrape and returns the metrics from stdout
https://github.com/lhns/prometheus-bash-exporter
bash exporter prometheus prometheus-exporter script
Last synced: 11 months ago
JSON representation
Prometheus metric exporter that executes a bash script on every scrape and returns the metrics from stdout
- Host: GitHub
- URL: https://github.com/lhns/prometheus-bash-exporter
- Owner: lhns
- License: apache-2.0
- Created: 2020-11-22T18:56:29.000Z (about 5 years ago)
- Default Branch: main
- Last Pushed: 2024-05-17T01:15:12.000Z (over 1 year ago)
- Last Synced: 2024-05-17T23:29:13.117Z (over 1 year ago)
- Topics: bash, exporter, prometheus, prometheus-exporter, script
- Language: Scala
- Homepage: https://github.com/users/lhns/packages/container/package/prometheus-bash-exporter
- Size: 273 KB
- Stars: 4
- Watchers: 3
- Forks: 1
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# prometheus-bash-exporter
[](https://github.com/lhns/prometheus-bash-exporter/actions?query=workflow%3Abuild)
[](https://github.com/lhns/prometheus-bash-exporter/releases/latest)
[](https://www.apache.org/licenses/LICENSE-2.0)
[](https://scala-steward.org)
Prometheus metric exporter that executes a bash script on every scrape and returns the metrics from stdout.
`$@` in the executed script will always contain the request path segments.
## Environment variables
- **LOG_LEVEL**: log level (default: ERROR)
- **SERVER_HOST**: listen host (default: 0.0.0.0)
- **SERVER_PORT**: listen port (default: 8080)
- **SCRIPT_METRICS**: script that is executed on `GET /metrics`
- **SCRIPT_TEST**: script that is executed on `GET /test`
- **CACHE_TEST**: cache the output of `GET /test` for 10 seconds
## Scripts
Head over to the [wiki](https://github.com/lhns/prometheus-bash-exporter/wiki) to see our collection of scripts.
## Docker builds
https://github.com/users/lhns/packages/container/package/prometheus-bash-exporter
## License
This project uses the Apache 2.0 License. See the file called LICENSE.