Commit 96e9e4011e7b60ea4208da0b326afc2ed9c53cd0
1 parent
4f752108
Exists in
master
Add docker compose for prometheus and grafana
Showing
2 changed files
with
32 additions
and
0 deletions
Show diff stats
@@ -0,0 +1,20 @@ | @@ -0,0 +1,20 @@ | ||
1 | +version: '3.8' | ||
2 | + | ||
3 | +services: | ||
4 | + prometheus: | ||
5 | + image: prom/prometheus | ||
6 | + restart: always | ||
7 | + volumes: | ||
8 | + - ./prometheus.yml:/etc/prometheus/prometheus.yml | ||
9 | + ports: | ||
10 | + - 9090:9090 | ||
11 | + | ||
12 | + grafana: | ||
13 | + image: grafana/grafana | ||
14 | + environment: | ||
15 | + GF_INSTALL_PLUGINS: "grafana-clock-panel,grafana-simple-json-datasource" | ||
16 | + restart: always | ||
17 | + ports: | ||
18 | + - 3000:3000 | ||
19 | + depends_on: | ||
20 | + - prometheus | ||
0 | \ No newline at end of file | 21 | \ No newline at end of file |
@@ -0,0 +1,12 @@ | @@ -0,0 +1,12 @@ | ||
1 | +global: | ||
2 | + scrape_interval: 15s | ||
3 | + evaluation_interval: 15s | ||
4 | + | ||
5 | +rule_files: | ||
6 | + # - "first.rules" | ||
7 | + # - "second.rules" | ||
8 | + | ||
9 | +scrape_configs: | ||
10 | + - job_name: prometheus | ||
11 | + static_configs: | ||
12 | + - targets: ['localhost:9090'] | ||
0 | \ No newline at end of file | 13 | \ No newline at end of file |