-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
35 lines (26 loc) · 741 Bytes
/
Dockerfile
File metadata and controls
35 lines (26 loc) · 741 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
31
32
33
34
35
# Stage 1: Build frontend
FROM node:22-slim AS frontend-builder
WORKDIR /frontend
COPY frontend/package.json frontend/bun.lock* ./
RUN npm install
COPY frontend/ .
ARG VITE_SUPABASE_URL
ARG VITE_SUPABASE_ANON_KEY
RUN npm run build
# Stage 2: Python server
FROM python:3.12-slim
# Install UV
COPY --from=ghcr.io/astral-sh/uv:latest /uv /usr/local/bin/uv
WORKDIR /app
# Copy dependency files first for caching
COPY pyproject.toml uv.lock* ./
# Install dependencies using UV
RUN uv sync --frozen --no-dev
# Copy source code
COPY src/ src/
# Copy frontend build output
COPY --from=frontend-builder /frontend/dist /app/frontend/dist
# Expose MCP server port
EXPOSE 8080
# Run the MCP server
CMD ["uv", "run", "python", "-m", "src.main"]