Ruperth commited on
Commit
be575e1
·
1 Parent(s): 07b3c1c

fix: drop the removed hf extra from the Dockerfile install step

Browse files

The optional dependency group named hf no longer exists in pyproject so uv was refusing to sync with extra hf. Transformers and torch are now part of the default dependency set so a plain sync is enough.

Files changed (1) hide show
  1. Dockerfile +2 -9
Dockerfile CHANGED
@@ -8,8 +8,6 @@ RUN npm run build
8
 
9
  FROM python:3.12-slim-bookworm
10
 
11
- ARG INSTALL_HF=1
12
-
13
  ENV PYTHONDONTWRITEBYTECODE=1 \
14
  PYTHONUNBUFFERED=1 \
15
  PYTHONPATH=/app \
@@ -18,8 +16,7 @@ ENV PYTHONDONTWRITEBYTECODE=1 \
18
  TRANSFORMERS_CACHE=/tmp/hf_cache \
19
  MODEL_NAME="Meta-Feature Stacking (Production)" \
20
  ENV=production \
21
- PORT=8000 \
22
- INSTALL_HF=${INSTALL_HF}
23
 
24
  WORKDIR /app
25
 
@@ -30,11 +27,7 @@ RUN apt-get update \
30
  COPY --from=ghcr.io/astral-sh/uv:latest /uv /usr/local/bin/uv
31
 
32
  COPY pyproject.toml uv.lock* README.md ./
33
- RUN if [ "$INSTALL_HF" = "1" ]; then \
34
- uv sync --frozen --no-dev --extra hf 2>/dev/null || uv sync --no-dev --extra hf; \
35
- else \
36
- uv sync --frozen --no-dev 2>/dev/null || uv sync --no-dev; \
37
- fi
38
 
39
  RUN uv run python -m spacy download en_core_web_sm \
40
  && uv run python - <<'PY'
 
8
 
9
  FROM python:3.12-slim-bookworm
10
 
 
 
11
  ENV PYTHONDONTWRITEBYTECODE=1 \
12
  PYTHONUNBUFFERED=1 \
13
  PYTHONPATH=/app \
 
16
  TRANSFORMERS_CACHE=/tmp/hf_cache \
17
  MODEL_NAME="Meta-Feature Stacking (Production)" \
18
  ENV=production \
19
+ PORT=8000
 
20
 
21
  WORKDIR /app
22
 
 
27
  COPY --from=ghcr.io/astral-sh/uv:latest /uv /usr/local/bin/uv
28
 
29
  COPY pyproject.toml uv.lock* README.md ./
30
+ RUN uv sync --frozen --no-dev 2>/dev/null || uv sync --no-dev
 
 
 
 
31
 
32
  RUN uv run python -m spacy download en_core_web_sm \
33
  && uv run python - <<'PY'