-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
91 lines (84 loc) · 2.2 KB
/
Copy pathdocker-compose.yml
File metadata and controls
91 lines (84 loc) · 2.2 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
name: workspaceos
networks:
workspaceos:
driver: bridge
services:
db:
image: pgvector/pgvector:pg15
restart: unless-stopped
networks:
- workspaceos
environment:
POSTGRES_DB: ${POSTGRES_DB}
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER} -d ${POSTGRES_DB}"]
interval: 5s
timeout: 5s
retries: 10
backend:
build:
context: ./backend
dockerfile: Dockerfile
restart: unless-stopped
networks:
- workspaceos
extra_hosts:
- "host.docker.internal:host-gateway"
ports:
- "9000:8000"
depends_on:
db:
condition: service_healthy
env_file:
- .env
volumes:
# Workspace scanner mount. Set WORKSPACE_HOST_PATH in .env to point at
# a directory on the host you want scanned (read-only). Defaults to
# /tmp/no-workspace so the demo runs without a real path; the scanner
# will return empty results.
- ${WORKSPACE_HOST_PATH:-/tmp/no-workspace}:/projects:ro
- backend_data:/app/data
- ./config:/app/config
command: >
sh -c "
alembic upgrade head &&
python seed.py || true &&
uvicorn app.main:app --host 0.0.0.0 --port 8000 --log-level info
"
working_dir: /app
frontend:
build:
context: ./frontend
dockerfile: Dockerfile
args:
NEXT_PUBLIC_API_BASE_URL: http://localhost:9000/api/v1
NEXT_PUBLIC_API_KEY: dev-secret-key
restart: unless-stopped
networks:
- workspaceos
ports:
- "4000:3000"
depends_on:
- backend
environment:
NEXT_PUBLIC_API_BASE_URL: ${NEXT_PUBLIC_API_BASE_URL}
NEXT_PUBLIC_API_KEY: ${NEXT_PUBLIC_API_KEY}
datamaster:
image: ${DATAMASTER_SIDECAR_IMAGE:-workspaceos/datamaster-sidecar:stub}
build: ./sidecars/datamaster
profiles: ["sidecars"]
networks:
- workspaceos
ports:
- "8800:8800"
env_file:
- path: ./sidecars/datamaster/.env
required: false
restart: unless-stopped
volumes:
postgres_data:
backend_data: