File tree 3 files changed +17
-0
lines changed
3 files changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -9,6 +9,9 @@ services:
9
9
environment :
10
10
SELF_SIGN : true
11
11
restart : " no"
12
+ metrics-db :
13
+ environment :
14
+ DATA_SOURCE_URI : db:5432/organize_development?sslmode=disable
12
15
site :
13
16
build :
14
17
target : dev
Original file line number Diff line number Diff line change @@ -41,6 +41,17 @@ services:
41
41
restart : always
42
42
volumes :
43
43
- metrics-data:/prometheus:rw
44
+ metrics-db :
45
+ command : ' --no-collector.stat_bgwriter'
46
+ depends_on :
47
+ - db
48
+ environment :
49
+ DATA_SOURCE_PASS : ${ORGANIZE_DATABASE_PASSWORD:?err}
50
+ DATA_SOURCE_URI : db:5432/organize_production?sslmode=disable
51
+ DATA_SOURCE_USER : postgres
52
+ image : prometheuscommunity/postgres-exporter:v0.15.0
53
+ ports :
54
+ - " 127.0.0.1:9187:9187"
44
55
site :
45
56
build :
46
57
context : site
Original file line number Diff line number Diff line change @@ -2,3 +2,6 @@ scrape_configs:
2
2
- job_name : prometheus
3
3
static_configs :
4
4
- targets : ['localhost:9090']
5
+ - job_name : postgres
6
+ static_configs :
7
+ - targets : ['metrics-db:9187']
You can’t perform that action at this time.
0 commit comments