Skip to content

Commit 7ae71c0

Browse files
committed
set up postgres monitoring with grafana, prometheus, and postgres-exporter
Signed-off-by: Adrian Edwards <adredwar@redhat.com>
1 parent 2c9a5f1 commit 7ae71c0

File tree

5 files changed

+3224
-0
lines changed

5 files changed

+3224
-0
lines changed

docker-compose.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,35 @@ services:
110110
# - rabbitmq
111111
# networks:
112112
# - augur
113+
114+
grafana:
115+
image: grafana/grafana
116+
ports:
117+
- 3000:3000
118+
environment:
119+
GF_SECURITY_ADMIN_USER: admin
120+
GF_SECURITY_ADMIN_PASSWORD: password
121+
GF_LOG_LEVEL: error
122+
DS_PROMETHEUS: Augur Postgres
123+
volumes:
124+
- ./gf_provisioning:/etc/grafana/provisioning:Z
125+
126+
prometheus:
127+
image: prom/prometheus
128+
ports:
129+
- 9090:9090
130+
volumes:
131+
- ./prometheus.yml:/etc/prometheus/prometheus.yml:z
132+
133+
postgres-exporter:
134+
image: quay.io/prometheuscommunity/postgres-exporter
135+
ports:
136+
- 9187:9187
137+
env_file: .env
138+
environment:
139+
DATA_SOURCE_URI: "augur-db:5432/augur?sslmode=disable"
140+
DATA_SOURCE_USER: "${AUGUR_DB_USER:-augur}"
141+
DATA_SOURCE_PASS: "${AUGUR_DB_PASSWORD:-augur}"
113142

114143
volumes:
115144
augurpostgres:

0 commit comments

Comments
 (0)