main
text 17 lines 399 Bytes
Raw
1 FROM python:3.12-slim
2
3 ENV PYTHONDONTWRITEBYTECODE=1 \
4 PYTHONUNBUFFERED=1 \
5 HOME=/tmp
6
7 WORKDIR /app
8 COPY pyproject.toml ./
9 COPY app ./app
10 RUN pip install --no-cache-dir . \
11 && groupadd --gid 10001 app \
12 && useradd --uid 10001 --gid 10001 --no-create-home --shell /usr/sbin/nologin app
13
14 USER 10001:10001
15 EXPOSE 8000
16
17 CMD ["python", "-m", "app.main", "--transport", "streamable-http"]