counting_words / Dockerfile
Agent
Stop re-resolving the spaCy model wheels on every container start
3a180ca
Raw History Blame Contribute Delete
587 Bytes
FROM ghcr.io/astral-sh/uv:0.9.5-python3.13-trixie-slim
RUN useradd -m -u 1000 user
ENV PATH="/home/user/.local/bin:$PATH"
ENV UV_SYSTEM_PYTHON=1
WORKDIR /app
RUN chown -R user:user /app
COPY --chown=user pyproject.toml uv.lock app.py /app
RUN chmod -R u+w /app
USER user
RUN uv sync --locked
# uv run re-resolves the two spaCy model wheels pinned by URL on every start,
# so without this the container waits on github.com before marimo boots.
ENV UV_NO_SYNC=1
CMD ["uv", "run", "marimo", "run", "app.py", "--no-sandbox", "--include-code", "--host", "0.0.0.0", "--port", "7860"]