Skip to content

Commit ad03b6a

Browse files
committed
feat(compose): add production config
1 parent ab4cdf5 commit ad03b6a

File tree

2 files changed

+32
-1
lines changed

2 files changed

+32
-1
lines changed

compose-dev.yaml

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ services:
44
build:
55
context: .
66
dockerfile: ./backend/api/Dockerfile
7+
entrypoint: bash -c "uv run fastapi run api/main.py --reload"
78
env_file:
89
- ./.env
9-
entrypoint: bash -c "uv run fastapi run api/main.py"
1010
ports:
1111
- 8000:8000
1212
volumes:
@@ -25,3 +25,17 @@ services:
2525
volumes:
2626
- ./backend/mcp:/app/mcp
2727
- ./backend/shared_mcp:/app/shared_mcp
28+
29+
api-builder:
30+
image: api:prod
31+
build:
32+
dockerfile_inline: |
33+
FROM api:dev
34+
ENTRYPOINT ["uv", "run", "fastapi", "run", "api/main.py"]
35+
36+
mcp-builder:
37+
image: mcp:prod
38+
build:
39+
dockerfile_inline: |
40+
FROM mcp:dev
41+
ENTRYPOINT ["uv", "run", "mcp/main.py"]

compose.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
services:
2+
api:
3+
image: api:prod
4+
env_file:
5+
- ./.env
6+
restart: unless-stopped
7+
healthcheck:
8+
test: curl -f http://localhost:8000/docs
9+
interval: 30s
10+
timeout: 10s
11+
retries: 3
12+
13+
mcp:
14+
image: mcp:prod
15+
env_file:
16+
- ./.env
17+
restart: unless-stopped

0 commit comments

Comments
 (0)