-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose-prometheus.yml
57 lines (53 loc) · 1.25 KB
/
docker-compose-prometheus.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
services:
gateway:
build:
dockerfile: gateway/Dockerfile
context: gateway
volumes:
- .:/opt/app/gateway
expose:
- "8080:8080"
environment:
CLUSTER_SECRET: "6ycQElx60By2aG66YqQoAmMemebZoQgEBTsph2KkdW8="
KNOWN_HOSTS: "img-proxy-worker-1"
HTTP_PORT: 8080
depends_on:
- worker
deploy:
replicas: 3
worker:
build:
dockerfile: worker/Dockerfile
context: worker
volumes:
- .:/opt/app/worker
environment:
CLUSTER_SECRET: "6ycQElx60By2aG66YqQoAmMemebZoQgEBTsph2KkdW8="
PORT: "8080"
KNOWN_HOSTS: "img-proxy-worker-1"
deploy:
replicas: 3
prometheus:
image: prom/prometheus
container_name: prometheus
command:
- '--config.file=/etc/prometheus/prometheus.yml'
ports:
- "9090:9090"
restart: unless-stopped
volumes:
- ./docker/prometheus:/etc/prometheus
- prom_data:/prometheus
grafana:
image: grafana/grafana
container_name: grafana
ports:
- "3000:3000"
restart: unless-stopped
environment:
- GF_SECURITY_ADMIN_USER=admin
- GF_SECURITY_ADMIN_PASSWORD=grafana
volumes:
- ./docker/grafana:/etc/grafana/provisioning/datasources
volumes:
prom_data: