Spaces:
Sleeping
Sleeping
Junjun Deng
commited on
Commit
·
9647ebb
1
Parent(s):
52e2399
Download model repo on docker build
Browse files- Dockerfile +11 -2
Dockerfile
CHANGED
|
@@ -1,7 +1,16 @@
|
|
| 1 |
FROM ghcr.io/huggingface/text-embeddings-inference:cpu-1.2
|
| 2 |
|
| 3 |
ARG MODEL_ID=Alibaba-NLP/gte-large-en-v1.5
|
| 4 |
-
ENV MODEL_ID=${MODEL_ID}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 5 |
|
| 6 |
ENTRYPOINT ["sh", "-c"]
|
| 7 |
-
CMD ["text-embeddings-router --model-id
|
|
|
|
| 1 |
FROM ghcr.io/huggingface/text-embeddings-inference:cpu-1.2
|
| 2 |
|
| 3 |
ARG MODEL_ID=Alibaba-NLP/gte-large-en-v1.5
|
| 4 |
+
# ENV MODEL_ID=${MODEL_ID}
|
| 5 |
+
|
| 6 |
+
# Install git and git-lfs
|
| 7 |
+
RUN apt-get update && apt-get install -y git git-lfs && rm -rf /var/lib/apt/lists/*
|
| 8 |
+
|
| 9 |
+
# Install and initialize git-lfs
|
| 10 |
+
RUN git lfs install
|
| 11 |
+
|
| 12 |
+
# Clone the repository
|
| 13 |
+
RUN git clone https://huggingface.co/${MODEL_ID} model
|
| 14 |
|
| 15 |
ENTRYPOINT ["sh", "-c"]
|
| 16 |
+
CMD ["text-embeddings-router --model-id model --port 8080"]
|