Skip to content

Commit ae09d64

Browse files
authored
Merge pull request #7 from import-ai/doc/compose
Update compose.yaml
2 parents 7a8abb4 + 5c12362 commit ae09d64

File tree

1 file changed

+28
-2
lines changed

1 file changed

+28
-2
lines changed

compose.yaml

Lines changed: 28 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ services:
1414
image: ghcr.io/import-ai/magic-box-backend:main
1515
restart: always
1616
environment:
17+
ENV: "prod"
1718
MBB_DB_URL: "postgresql+asyncpg://magic_box:magic_box@postgres:5432/magic_box"
1819
MBB_WIZARD_BASE_URL: "http://wizard:8000"
1920
healthcheck:
@@ -24,18 +25,19 @@ services:
2425
depends_on:
2526
wizard:
2627
condition: service_healthy
28+
wizard-worker:
29+
condition: service_healthy
2730
postgres:
2831
condition: service_healthy
2932

3033
wizard:
3134
image: ghcr.io/import-ai/magic-box-wizard:main
3235
restart: always
3336
environment:
37+
ENV: "prod"
3438
MBW_DB_URL: "postgresql+asyncpg://magic_box:magic_box@postgres:5432/magic_box"
35-
3639
MBW_VECTOR_HOST: chromadb
3740
MBW_VECTOR_PORT: 8000
38-
3941
MBW_BACKEND_BASE_URL: "http://backend:8000"
4042
env_file:
4143
- .env
@@ -50,6 +52,30 @@ services:
5052
postgres:
5153
condition: service_healthy
5254

55+
wizard-worker:
56+
image: ghcr.io/import-ai/magic-box-wizard:main
57+
restart: always
58+
environment:
59+
ENV: "prod"
60+
MBW_DB_URL: "postgresql+asyncpg://magic_box:magic_box@postgres:5432/magic_box"
61+
MBW_VECTOR_HOST: chromadb
62+
MBW_VECTOR_PORT: 8000
63+
MBW_BACKEND_BASE_URL: "http://backend:8000"
64+
entrypoint: ["python", "main.py"]
65+
command: ["--workers", "1"]
66+
env_file:
67+
- .env
68+
healthcheck:
69+
test: ["CMD-SHELL", "pgrep python"]
70+
interval: 30s
71+
timeout: 10s
72+
retries: 5
73+
depends_on:
74+
wizard:
75+
condition: service_healthy
76+
postgres:
77+
condition: service_healthy
78+
5379
postgres:
5480
image: postgres:17-alpine
5581
restart: always

0 commit comments

Comments
 (0)