-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
65 lines (60 loc) · 1.48 KB
/
docker-compose.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
58
59
60
61
62
63
64
65
version: "3.8"
services:
postgres:
image: postgres:latest
restart: unless-stopped
container_name: eventify_postgres
environment:
POSTGRES_USER: ${POSTGRES_USER:-postgres}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-password}
POSTGRES_DB: ${POSTGRES_DB:-eventify}
ports:
- "${POSTGRES_PORT:-5432}:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-postgres}"]
interval: 10s
timeout: 5s
retries: 5
networks:
- default
redis:
image: redis:6.2
restart: unless-stopped
container_name: eventify_redis
environment:
- ALLOW_EMPTY_PASSWORD=yes
ports:
- "6379:6379"
command: redis-server --save 20 1 --loglevel warning
volumes:
- redis_data:/data
networks:
- default
eventify:
depends_on:
- postgres
- redis
build:
context: .
dockerfile: ./Dockerfile
args:
BUILD_PROFILE: dev
container_name: eventify
environment:
RUST_LOG: trace
DATABASE_URL: postgresql://${POSTGRES_USER:-postgres}:${POSTGRES_PASSWORD:-password}@postgres:5432/${POSTGRES_DB:-eventify}
EVENTIFY_QUEUE_URL: redis://redis:6379
ports:
- "21420:21420"
entrypoint:
["/app/eventify", "run", "--config", "/app/etc/configs/stream-all.toml"]
networks:
- default
networks:
default:
driver: bridge
volumes:
postgres_data:
redis_data: