-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
30 lines (29 loc) · 914 Bytes
/
Copy pathdocker-compose.yml
File metadata and controls
30 lines (29 loc) · 914 Bytes
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
# Lives at the monorepo root because the image build needs the root lockfile
# and packages/* in its context (the root Dockerfile explains why).
services:
codegraph:
build:
context: .
dockerfile: Dockerfile
image: codegraph-app:latest
ports:
- "4000:4000"
environment:
# Public base URL the app advertises for itself (e.g. marketing "Start Indexing" links).
NEXT_PUBLIC_APP_URL: ${NEXT_PUBLIC_APP_URL:-http://localhost:4000}
volumes:
# Persist the SQLite DB + WAL across container restarts.
- codegraph-data:/app/data
restart: unless-stopped
healthcheck:
test:
- CMD
- node
- -e
- "fetch('http://127.0.0.1:4000/api/health').then(r=>{if(r.status!==200)process.exit(1)}).catch(()=>process.exit(1))"
interval: 30s
timeout: 5s
start_period: 20s
retries: 3
volumes:
codegraph-data: