-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
54 lines (50 loc) · 1.09 KB
/
docker-compose.yml
File metadata and controls
54 lines (50 loc) · 1.09 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
services:
postgres:
container_name: topicstreams-postgres
image: postgres:18-alpine
env_file:
- .env
volumes:
- postgres_data:/var/lib/postgresql/data
- ./postgres/init.sql:/docker-entrypoint-initdb.d/init.sql
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER} -d ${POSTGRES_DB}"]
interval: 10s
timeout: 5s
retries: 5
networks:
- topicstreams-network
api:
container_name: topicstreams-api
build:
context: .
target: api
env_file:
- .env
ports:
- "${HOST_PORT:-80}:${API_PORT}"
depends_on:
postgres:
condition: service_healthy
restart: unless-stopped
networks:
- topicstreams-network
scraper:
container_name: topicstreams-scraper
build:
context: .
target: scraper
env_file:
- .env
depends_on:
postgres:
condition: service_healthy
restart: unless-stopped
networks:
- topicstreams-network
volumes:
postgres_data:
driver: local
networks:
topicstreams-network:
driver: bridge