-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathcompose.dev.yml
More file actions
105 lines (97 loc) · 3.54 KB
/
compose.dev.yml
File metadata and controls
105 lines (97 loc) · 3.54 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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
# =============================================================================
# LOCAL DEVELOPMENT OVERRIDES
# =============================================================================
# Extends compose.yml with source mounts, relaxed health checks, and
# debug-level logging for a faster edit-reload cycle.
#
# Usage:
# docker compose -f compose.yml -f compose.dev.yml up --build
#
# Note: Hot-reload requires the service to support file-watching.
# - Platform: Vite HMR (automatic)
# - RAG/Crawler: uvicorn --reload (set via env var below)
# =============================================================================
services:
crawler:
volumes:
- ./services/crawler/app:/app/app
- crawler-data:/app/data
environment:
- CRAWLER_LOG_LEVEL=debug
# Enable uvicorn auto-reload for Python code changes
- UVICORN_RELOAD=true
command:
[
'uvicorn',
'app.main:app',
'--host',
'0.0.0.0',
'--port',
'8002',
'--reload',
]
healthcheck:
interval: 30s
timeout: 10s
retries: 5
start_period: 60s
rag:
volumes:
- ./services/rag/app:/app/app
- rag-data:/app/data
environment:
- RAG_LOG_LEVEL=debug
# Phase 2 (split): convex gets live source for hot-reloadable functions
# and the Dashboard, and owns the data volume. Platform mounts convex-data
# read-only for config watching + branding image serving only.
convex:
volumes:
- ./services/platform/convex:/app/convex
- convex-data:/app/data
- caddy-data:/caddy-data:ro
environment:
- RUST_LOG=debug
# NODE_ENV is read by Convex V8 functions at evaluation time; the
# `test_sandbox_e2e` action gates itself on this so production can't
# accidentally invoke the E2E harness. Dev compose explicitly opts in.
- NODE_ENV=development
platform:
volumes:
- ./services/platform/app:/app/services/platform/app
- ./services/platform/lib:/app/services/platform/lib
- ./services/platform/convex:/app/services/platform/convex
# `bunx convex deploy` runs from /app (the package.json with
# "convex": "1.35.x") and looks for source at `<cwd>/convex/`,
# which is the image-baked snapshot. Bind the host source over
# that path too so deploys pick up live edits instead of the
# snapshot frozen at build time.
- ./services/platform/convex:/app/convex
- convex-data:/app/data:ro
environment:
- NODE_ENV=development
docs:
volumes:
- ./services/docs/app:/app/services/docs/app
- ./services/docs/lib:/app/services/docs/lib
- ./services/docs/messages:/app/services/docs/messages
- ./services/docs/scripts:/app/services/docs/scripts
environment:
- NODE_ENV=development
proxy:
environment:
- CADDY_DEBUG=true
# Sandbox-wobbly-origami plan §4: when developers run Convex on the host
# (e.g. `cd services/platform && bun dev` instead of the dockerized
# `convex` service), the spawner container needs to reach
# http://host.docker.internal:3210 for the EP1/EP2 callbacks. Linux
# Docker doesn't add this DNS alias by default; the line below opts in.
# In that bun-dev setup, also set in `services/platform/.env.local`:
# SANDBOX_STORAGE_INTERNAL_BASE_URL=http://host.docker.internal:3210
# The dockerized convex path uses `http://proxy` from compose.yml.
sandbox:
extra_hosts:
- 'host.docker.internal:host-gateway'
db:
environment:
- DB_LOG_STATEMENT=all
- DB_LOG_MIN_DURATION_STATEMENT=0