build: add dockerfile for constructing backend

This commit is contained in:
2026-03-03 12:08:12 +00:00
parent c767f59b26
commit 14b472ea60
2 changed files with 24 additions and 1 deletions

19
Dockerfile Normal file
View File

@@ -0,0 +1,19 @@
# Use slim to reduce size
FROM python:3.13-slim
# Prevent Python from buffering stdout
ENV PYTHONUNBUFFERED=1
# System deps required for psycopg2 + torch
RUN apt-get update && apt-get install -y \
build-essential \
libpq-dev \
gcc \
curl \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY . .
CMD ["python", "main.py"]