m-newhauser commited on
Commit
f17e84a
·
verified ·
1 Parent(s): 55f70b7

Upload folder using huggingface_hub

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -1
Dockerfile CHANGED
@@ -11,12 +11,17 @@ ENV HOME=/home/user \
11
 
12
  WORKDIR /home/user/app
13
 
 
 
 
 
 
14
  # CPU-only torch (default PyPI wheel is CUDA and huge). Only needed for the real
15
  # model; the mock path works on flask alone.
16
  RUN pip install --no-cache-dir --user torch --index-url https://download.pytorch.org/whl/cpu
17
  RUN pip install --no-cache-dir --user flask gunicorn protobuf
18
  # GLiNER2 from testg2 branch (required for boundary architecture support)
19
- RUN pip install --no-cache-dir --user "git+https://github.com/fastino-ai/GLiNER2.git@testg2#egg=gliner2[local]"
20
 
21
  COPY --chown=user . .
22
 
 
11
 
12
  WORKDIR /home/user/app
13
 
14
+ # git needed to pip-install gliner2 from GitHub branch
15
+ USER root
16
+ RUN apt-get update && apt-get install -y --no-install-recommends git && rm -rf /var/lib/apt/lists/*
17
+ USER user
18
+
19
  # CPU-only torch (default PyPI wheel is CUDA and huge). Only needed for the real
20
  # model; the mock path works on flask alone.
21
  RUN pip install --no-cache-dir --user torch --index-url https://download.pytorch.org/whl/cpu
22
  RUN pip install --no-cache-dir --user flask gunicorn protobuf
23
  # GLiNER2 from testg2 branch (required for boundary architecture support)
24
+ RUN pip install --no-cache-dir --user "gliner2[local] @ git+https://github.com/fastino-ai/GLiNER2.git@testg2"
25
 
26
  COPY --chown=user . .
27