-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
40 lines (38 loc) · 1.08 KB
/
Copy pathdocker-compose.yml
File metadata and controls
40 lines (38 loc) · 1.08 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
services:
db:
image: postgres:17
restart: unless-stopped
environment:
POSTGRES_DB: horizon
POSTGRES_USER: horizon
POSTGRES_PASSWORD: 123UsedForTestOnly
POSTGRES_INITDB_ARGS: --encoding=UTF-8 --lc-collate=C --lc-ctype=C
ports:
- 5432:5432
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: [CMD-SHELL, 'pg_isready -d $${POSTGRES_DB} -U $${POSTGRES_USER}']
start_period: 5s
interval: 30s
timeout: 5s
retries: 3
backend:
image: mtsrus/horizon-backend:${VERSION:-latest}
restart: unless-stopped
environment:
# PROMETHEUS_MULTIPROC_DIR is required for multiple workers, see:
# https://prometheus.github.io/client_python/multiprocess/
PROMETHEUS_MULTIPROC_DIR: /tmp/prometheus-metrics
# tmpfs dir is cleaned up each container restart
tmpfs:
- /tmp/prometheus-metrics:mode=1777
volumes:
- ./config.docker.yml:/app/config.yml:ro
ports:
- 8000:8000
depends_on:
db:
condition: service_healthy
volumes:
postgres_data: