-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathcompose.yml
More file actions
104 lines (98 loc) · 2.55 KB
/
Copy pathcompose.yml
File metadata and controls
104 lines (98 loc) · 2.55 KB
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
services:
pogocache:
build:
context: .
dockerfile: docker/pogocache.Dockerfile
container_name: nexq-pogocache
ports:
- "9401:9401"
command: ["-h", "0.0.0.0", "-p", "9401"]
healthcheck:
test: ["CMD-SHELL", "echo 'PING' | nc -w 1 localhost 9401 | grep -q PONG"]
interval: 10s
timeout: 5s
retries: 3
start_period: 5s
postgres:
image: postgres:18-alpine
ports:
- "5432:5432"
environment:
POSTGRES_USER: nexq
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_DB: nexq
volumes:
- postgres-data:/var/lib/postgresql/data
- ./migrations:/docker-entrypoint-initdb.d
healthcheck:
test: ["CMD-SHELL", "pg_isready -U nexq -d nexq"]
interval: 10s
timeout: 5s
retries: 5
victoriametrics:
image: victoriametrics/victoria-metrics:v1.133.0
ports:
- "8428:8428"
extra_hosts:
- "host.docker.internal:host-gateway"
volumes:
- ./config/victoriametrics.yml:/etc/victoriametrics/scrape.yml:ro
- victoriametrics-data:/victoria-metrics-data
command:
- "-promscrape.config=/etc/victoriametrics/scrape.yml"
- "-storageDataPath=/victoria-metrics-data"
- "-retentionPeriod=1"
- "-httpListenAddr=:8428"
restart: unless-stopped
grafana:
image: grafana/grafana
ports:
- "3000:3000"
environment:
- GF_SECURITY_ADMIN_PASSWORD=${GF_SECURITY_ADMIN_PASSWORD}
- GF_USERS_ALLOW_SIGN_UP=false
volumes:
- grafana-data:/var/lib/grafana
- ./config/grafana/provisioning:/etc/grafana/provisioning:ro
depends_on:
- victoriametrics
server:
build:
context: .
dockerfile: docker/server.Dockerfile
container_name: nexq-server
ports:
- "8080:8080"
environment:
- POSTGRES_DSN=${POSTGRES_DSN}
- POGOCACHE_ADDR=pogocache:9401
depends_on:
pogocache:
condition: service_healthy
postgres:
condition: service_healthy
restart: unless-stopped
volumes:
- reports-data:/app/reports
worker:
build:
context: .
dockerfile: docker/worker.Dockerfile
container_name: nexq-worker
environment:
- POGOCACHE_ADDR=pogocache:9401
- POSTGRES_DSN=${POSTGRES_DSN}
- WORKER_ID=worker-1
depends_on:
pogocache:
condition: service_healthy
postgres:
condition: service_healthy
restart: unless-stopped
volumes:
- reports-data:/app/reports
volumes:
postgres-data:
victoriametrics-data:
grafana-data:
reports-data: