Spaces:
Sleeping
Sleeping
Create Dockerfile
Browse files- Dockerfile +17 -0
Dockerfile
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
FROM python:3.10-slim
|
| 2 |
+
|
| 3 |
+
RUN apt-get update && apt-get install -y \
|
| 4 |
+
gcc g++ make cmake git libopenblas-dev wget \
|
| 5 |
+
&& rm -rf /var/lib/apt/lists/*
|
| 6 |
+
|
| 7 |
+
# Prebuilt llama-cpp-python для HF CPU (OpenBLAS)
|
| 8 |
+
RUN pip install --no-cache-dir \
|
| 9 |
+
https://huggingface.co/Luigi/llama-cpp-python-wheels-hf-spaces-free-cpu/resolve/main/llama_cpp_python-0.3.22-cp310-cp310-linux_x86_64.whl
|
| 10 |
+
|
| 11 |
+
RUN pip install huggingface-hub fastapi uvicorn
|
| 12 |
+
|
| 13 |
+
WORKDIR /app
|
| 14 |
+
COPY app.py .
|
| 15 |
+
|
| 16 |
+
EXPOSE 7860
|
| 17 |
+
CMD ["python", "app.py"]
|