-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yaml
More file actions
65 lines (60 loc) · 1.25 KB
/
docker-compose.yaml
File metadata and controls
65 lines (60 loc) · 1.25 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
services:
backend:
build:
context: ./
dockerfile: Dockerfile
container_name: app
entrypoint: ./scripts/app_entrypoint.sh
ports:
- 8000:8000
networks:
- network
environment:
- DATABASE_URL=${DATABASE_URL:-postgresql+asyncpg://user:password@postgres:5432/app_db}
depends_on:
- postgres
env_file:
- .env
celery:
build:
context: ./
dockerfile: Dockerfile
container_name: celery
entrypoint: ./scripts/celery_entrypoint.sh
networks:
- network
depends_on:
- postgres
- redis
environment:
- REDIS_URL= ${REDIS_URL:-redis://redis:6379/0}
- REDIS_BROKER_URL=${REDIS_BROKER_URL:-redis://redis:6379/1}
env_file:
- .env
redis:
image: redis:latest
container_name: redis
restart: always
networks:
- network
ports:
- 6379:6379
postgres:
image: postgres:latest
container_name: postgres
restart: always
ports:
- 5432:5432
networks:
- network
environment:
POSTGRES_USER: user
POSTGRES_DB: app_db
POSTGRES_PASSWORD: password
volumes:
- postgres_data:/var/lib/postgresql/data
volumes:
postgres_data:
networks:
network:
driver: bridge