Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- Dockerfile +8 -2
Dockerfile
CHANGED
|
@@ -2,9 +2,15 @@ FROM python:3.10-slim
|
|
| 2 |
|
| 3 |
WORKDIR /app
|
| 4 |
|
| 5 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6 |
|
| 7 |
-
# Cài đặt các thư viện Python cần thiết
|
| 8 |
COPY requirements.txt .
|
| 9 |
RUN pip install --no-cache-dir -r requirements.txt
|
| 10 |
|
|
|
|
| 2 |
|
| 3 |
WORKDIR /app
|
| 4 |
|
| 5 |
+
# Cài đặt các thư viện hệ thống cần thiết cho OpenBLAS
|
| 6 |
+
RUN apt-get update && apt-get install -y --no-install-recommends \
|
| 7 |
+
gcc g++ make cmake git libopenblas-dev \
|
| 8 |
+
&& rm -rf /var/lib/apt/lists/*
|
| 9 |
+
|
| 10 |
+
# Cài đặt llama-cpp-python từ wheel ĐÃ BIÊN DỊCH SẴN (không cần build)
|
| 11 |
+
RUN pip install --no-cache-dir \
|
| 12 |
+
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
|
| 13 |
|
|
|
|
| 14 |
COPY requirements.txt .
|
| 15 |
RUN pip install --no-cache-dir -r requirements.txt
|
| 16 |
|