Updated Prometheus Exporter (markdown)

master
Hunter Long 2018-07-12 21:31:21 -07:00
parent 0eec71bc1c
commit 4cec7edf17
1 changed files with 18 additions and 4 deletions

@ -1,5 +1,12 @@
Statup includes a prometheus exporter so you can have even more monitoring power with your services. The prometheus exporter can be seen on `/metrics`, simply create another exporter in your prometheus config. Use your Statup API Secret for the Authorization Bearer header, the `/metrics` URL is dedicated for Prometheus and requires the correct API Secret has `Authorization` header.
# Grafana Dashboard
Statup has a [Grafana Dashboard](https://grafana.com/dashboards/6950) that you can quickly implement if you've added your Statup service to Prometheus. Import Dashboard ID: `6950` into your Grafana dashboard and watch the metrics come in!
<p align="center"><img width="80%" src="https://img.cjx.io/statupgrafana.png"></p>
## Basic Prometheus Exporter
If you have Statup and the Prometheus server in the same Docker network, you can use the yaml config below.
```yaml
scrape_configs:
- job_name: 'statup'
@ -9,10 +16,17 @@ scrape_configs:
- targets: ['statup:8080']
```
# Grafana Dashboard
Statup has a [Grafana Dashboard](https://grafana.com/dashboards/6950) that you can quickly implement if you've added your Statup service to Prometheus. Import Dashboard ID: `6950` into your Grafana dashboard and watch the metrics come in!
<p align="center"><img width="80%" src="https://img.cjx.io/statupgrafana.png"></p>
## Remote URL Prometheus Exporter
This exporter yaml below has `scheme: https`, which you can remove if you arn't using HTTPS.
```yaml
scrape_configs:
- job_name: 'statup'
scheme: https
scrape_interval: 30s
bearer_token: 'SECRET API KEY HERE'
static_configs:
- targets: ['status.mydomain.com']
```
### `/metrics` Output
```