29 lines
752 B
Docker
29 lines
752 B
Docker
FROM python:3.12-slim
|
|
|
|
ENV PYTHONDONTWRITEBYTECODE=1 \
|
|
PYTHONUNBUFFERED=1 \
|
|
PIP_DISABLE_PIP_VERSION_CHECK=1
|
|
|
|
WORKDIR /app
|
|
|
|
RUN apt-get update \
|
|
&& apt-get install -y --no-install-recommends ca-certificates \
|
|
&& rm -rf /var/lib/apt/lists/* \
|
|
&& groupadd --gid 10001 primethai \
|
|
&& useradd --uid 10001 --gid primethai --create-home --shell /usr/sbin/nologin primethai
|
|
|
|
COPY pyproject.toml README.md ./
|
|
COPY primethai/ ./primethai/
|
|
RUN python -m pip install --no-cache-dir .
|
|
|
|
COPY --chown=10001:10001 config/ ./config/
|
|
COPY --chown=10001:10001 data/ ./data/
|
|
COPY --chown=10001:10001 reports/ ./reports/
|
|
|
|
USER 10001:10001
|
|
|
|
EXPOSE 18900
|
|
|
|
ENTRYPOINT ["python", "-m", "primethai", "webui"]
|
|
CMD ["--host", "0.0.0.0", "--port", "18900"]
|