Upload Dockerfile (1).txt
Browse files- Dockerfile (1).txt +19 -0
Dockerfile (1).txt
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
FROM python:3.10-slim
|
| 2 |
+
|
| 3 |
+
WORKDIR /app
|
| 4 |
+
|
| 5 |
+
RUN apt-get update && apt-get install -y \
|
| 6 |
+
git \
|
| 7 |
+
git-lfs \
|
| 8 |
+
libgl1 \
|
| 9 |
+
libglib2.0-0 \
|
| 10 |
+
&& git lfs install \
|
| 11 |
+
&& rm -rf /var/lib/apt/lists/*
|
| 12 |
+
|
| 13 |
+
RUN --mount=type=secret,id=HF_TOKEN \
|
| 14 |
+
--mount=type=secret,id=HF_REPO \
|
| 15 |
+
git clone https://user:$(cat /run/secrets/HF_TOKEN)@huggingface.co/spaces/$(cat /run/secrets/HF_REPO).git .
|
| 16 |
+
|
| 17 |
+
RUN pip install -r requirements.txt
|
| 18 |
+
|
| 19 |
+
CMD ["python", "app.py"]
|