Repository navigation
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
86 lines (81 loc) · 1.71 KB
/
Copy pathdocker-compose.yml
File metadata and controls
86 lines (81 loc) · 1.71 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
services:
# Local Postgres — only started when you run:
# docker compose --profile localdb up
# In production, point DB_HOST at your Supabase DB instead.
db:
image: pgvector/pgvector:pg16
profiles: ["localdb"]
environment:
POSTGRES_DB: rfp_db
POSTGRES_USER: rfp_user
POSTGRES_PASSWORD: rfp_pass
volumes:
- pgdata:/var/lib/postgresql/data
ports:
- "5432:5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U rfp_user -d rfp_db"]
interval: 5s
timeout: 5s
retries: 5
redis:
image: redis:7-alpine
ports:
- "6379:6379"
backend:
build:
context: ./backend
dockerfile: Dockerfile
command: python manage.py runserver 0.0.0.0:8000
volumes:
- ./backend:/app
- media_vol:/app/media
ports:
- "8000:8000"
env_file:
- .env
environment:
- PORT=8000
- DB_HOST=db
depends_on:
redis:
condition: service_started
dns:
- 8.8.8.8
- 8.8.4.4
worker:
build:
context: ./backend
dockerfile: Dockerfile
command: celery -A config worker --loglevel=info
volumes:
- ./backend:/app
- media_vol:/app/media
env_file:
- .env
environment:
- DB_HOST=db
healthcheck:
disable: true
depends_on:
- backend
- redis
dns:
- 8.8.8.8
- 8.8.4.4
frontend:
build:
context: ./frontend
dockerfile: Dockerfile
ports:
- "5173:5173"
volumes:
- ./frontend/src:/app/src
environment:
- VITE_PROXY_TARGET=http://backend:8000
- VITE_GOOGLE_CLIENT_ID=${VITE_GOOGLE_CLIENT_ID}
depends_on:
- backend
volumes:
pgdata:
media_vol: