add pushgateway
This commit is contained in:
parent
a9b76dff65
commit
1a59dfac7f
@ -17,6 +17,10 @@ ENABLE_BACKUPS=true
|
|||||||
## Prometheus
|
## Prometheus
|
||||||
# COMPOSE_FILE="$COMPOSE_FILE:compose.prometheus.yml"
|
# COMPOSE_FILE="$COMPOSE_FILE:compose.prometheus.yml"
|
||||||
# PROMETHEUS_RETENTION_TIME=1y
|
# PROMETHEUS_RETENTION_TIME=1y
|
||||||
|
#
|
||||||
|
## Prometheus Pushgateway
|
||||||
|
# COMPOSE_FILE="$COMPOSE_FILE:compose.pushgateway.yml"
|
||||||
|
#
|
||||||
## Loki
|
## Loki
|
||||||
# Loki Server
|
# Loki Server
|
||||||
#
|
#
|
||||||
|
@ -101,8 +101,17 @@ $ echo '{
|
|||||||
$ systemctl restart docker.service
|
$ systemctl restart docker.service
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Setup Push Gateway
|
||||||
|
|
||||||
|
1. Enable in the env fiöle by uncommenting the following lines:
|
||||||
|
```
|
||||||
|
## Prometheus Pushgateway
|
||||||
|
# COMPOSE_FILE="$COMPOSE_FILE:compose.pushgateway.yml"
|
||||||
|
```
|
||||||
|
2. `abra app deploy monitoring.example.org`
|
||||||
|
|
||||||
|
This will expose the pushgateway at `https://pushgateway.${DOMAIN}`.
|
||||||
|
It is secured behind the same basic auth as the other services.
|
||||||
|
|
||||||
## Post-setup guide
|
## Post-setup guide
|
||||||
|
|
||||||
|
25
compose.pushgateway.yml
Normal file
25
compose.pushgateway.yml
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
version: '3.8'
|
||||||
|
|
||||||
|
services:
|
||||||
|
pushgateway:
|
||||||
|
image: prom/pushgateway:v1.10.0
|
||||||
|
command:
|
||||||
|
- '--web.listen-address=:9191'
|
||||||
|
- '--push.disable-consistency-check'
|
||||||
|
- '--persistence.interval=5m'
|
||||||
|
ports:
|
||||||
|
- 9191:9191
|
||||||
|
networks:
|
||||||
|
- internal
|
||||||
|
- proxy
|
||||||
|
deploy:
|
||||||
|
restart_policy:
|
||||||
|
condition: on-failure
|
||||||
|
labels:
|
||||||
|
- "traefik.enable=true"
|
||||||
|
- "traefik.http.services.${STACK_NAME}-pushgateway.loadbalancer.server.port=9191"
|
||||||
|
- "traefik.http.routers.${STACK_NAME}-pushgateway.rule=Host(`pushgateway.${DOMAIN}`)"
|
||||||
|
- "traefik.http.routers.${STACK_NAME}-pushgateway.entrypoints=web-secure"
|
||||||
|
- "traefik.http.routers.${STACK_NAME}-pushgateway.tls=true"
|
||||||
|
- "traefik.http.routers.${STACK_NAME}-pushgateway.tls.certresolver=${LETS_ENCRYPT_ENV}"
|
||||||
|
- "traefik.http.routers.${STACK_NAME}-pushgateway.middlewares=basicauth@file"
|
Loading…
x
Reference in New Issue
Block a user