@@ -26,7 +26,14 @@ services:
26
26
POSTGRES_DB :target_database
27
27
POSTGRES_USER :postgres
28
28
POSTGRES_PASSWORD :postgres
29
- command :["postgres", "-c", "shared_preload_libraries=pg_stat_statements", "-c", "pg_stat_statements.track=all"]
29
+ command :
30
+ [
31
+ " postgres" ,
32
+ " -c" ,
33
+ " shared_preload_libraries=pg_stat_statements" ,
34
+ " -c" ,
35
+ " pg_stat_statements.track=all" ,
36
+ ]
30
37
ports :
31
38
-" 55432:5432"
32
39
volumes :
@@ -57,18 +64,24 @@ services:
57
64
-./config/prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
58
65
-prometheus_data:/prometheus
59
66
command :
60
- -' --config.file=/etc/prometheus/prometheus.yml'
61
- -' --storage.tsdb.path=/prometheus'
62
- -' --web.console.libraries=/etc/prometheus/console_libraries'
63
- -' --web.console.templates=/etc/prometheus/consoles'
64
- -' --storage.tsdb.retention.time=200h'
65
- -' --web.enable-lifecycle'
67
+ -" --config.file=/etc/prometheus/prometheus.yml"
68
+ -" --storage.tsdb.path=/prometheus"
69
+ -" --web.console.libraries=/etc/prometheus/console_libraries"
70
+ -" --web.console.templates=/etc/prometheus/consoles"
71
+ -" --storage.tsdb.retention.time=200h"
72
+ -" --web.enable-lifecycle"
66
73
67
74
# PGWatch Instance 1 - Monitoring service (Postgres sink)
68
75
pgwatch-postgres :
69
76
image :cybertecpostgresql/pgwatch:3
70
77
container_name :pgwatch-postgres
71
- command :["--sources=/etc/pgwatch/sources.yml", "--metrics=/etc/pgwatch/metrics.yml", "--sink=postgresql://pgwatch:pgwatchadmin@sink-postgres:5432/measurements", "--web-addr=:8080"]
78
+ command :
79
+ [
80
+ " --sources=/etc/pgwatch/sources.yml" ,
81
+ " --metrics=/etc/pgwatch/metrics.yml" ,
82
+ " --sink=postgresql://pgwatch:pgwatchadmin@sink-postgres:5432/measurements" ,
83
+ " --web-addr=:8080" ,
84
+ ]
72
85
ports :
73
86
-" 58080:8080"
74
87
depends_on :
@@ -82,7 +95,13 @@ services:
82
95
pgwatch-prometheus :
83
96
image :cybertecpostgresql/pgwatch:3
84
97
container_name :pgwatch-prometheus
85
- command :["--sources=/etc/pgwatch/sources.yml", "--metrics=/etc/pgwatch/metrics.yml", "--sink=prometheus://0.0.0.0:9091/pgwatch", "--web-addr=:8089"]
98
+ command :
99
+ [
100
+ " --sources=/etc/pgwatch/sources.yml" ,
101
+ " --metrics=/etc/pgwatch/metrics.yml" ,
102
+ " --sink=prometheus://0.0.0.0:9091/pgwatch" ,
103
+ " --web-addr=:8089" ,
104
+ ]
86
105
ports :
87
106
-" 58089:8089"
88
107
-" 59091:9091"
@@ -99,7 +118,7 @@ services:
99
118
container_name :grafana-with-datasources
100
119
environment :
101
120
GF_SECURITY_ADMIN_USER :monitor
102
- GF_SECURITY_ADMIN_PASSWORD :${GRAFANA_PASSWORD :-demo}
121
+ GF_SECURITY_ADMIN_PASSWORD :${GF_SECURITY_ADMIN_PASSWORD :-demo}
103
122
GF_INSTALL_PLUGINS :yesoreyeram-infinity-datasource
104
123
ports :
105
124
-" 3000:3000"