File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed
Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -10,14 +10,21 @@ RUN apt-get update -y && \
1010 curl -LsSf https://astral.sh/uv/install.sh | sh && \
1111 mv /root/.local/bin/uv /usr/local/bin/ && \
1212 mv /root/.local/bin/uvx /usr/local/bin/ && \
13- curl https://sh.rustup.rs -sSf | sh -s -- -y && \
1413 useradd -m -u 1000 appuser && \
1514 mkdir -p /app/api/src/models/v1_0 && \
1615 chown -R appuser:appuser /app
1716
1817USER appuser
1918WORKDIR /app
2019
20+ # Install Rust for the non-root user so builds (e.g., sudachipy) succeed
21+ RUN curl https://sh.rustup.rs -sSf | sh -s -- -y
22+
23+ # Ensure Cargo and the Python venv are on PATH; extend HTTP timeouts for uv
24+ ENV PATH="/home/appuser/.cargo/bin:/app/.venv/bin:$PATH" \
25+ UV_HTTP_TIMEOUT=120 \
26+ UV_HTTP_RETRIES=3
27+
2128# Copy dependency files
2229COPY --chown=appuser:appuser pyproject.toml ./pyproject.toml
2330
@@ -32,8 +39,7 @@ COPY --chown=appuser:appuser docker/scripts/ ./
3239RUN chmod +x ./entrypoint.sh
3340
3441# Set environment variables
35- ENV PATH="/home/appuser/.cargo/bin:/app/.venv/bin:$PATH" \
36- PYTHONUNBUFFERED=1 \
42+ ENV PYTHONUNBUFFERED=1 \
3743 PYTHONPATH=/app:/app/api \
3844 UV_LINK_MODE=copy \
3945 USE_GPU=false \
You can’t perform that action at this time.
0 commit comments