nihardon commited on
Commit
58a5bfc
·
verified ·
1 Parent(s): 41fb684

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +11 -18
Dockerfile CHANGED
@@ -1,25 +1,18 @@
1
- FROM python:3.10-slim
2
 
3
- # Install system tools needed for the wheel
4
- RUN apt-get update && apt-get install -y \
5
- build-essential \
6
- curl \
7
- && pip install --upgrade pip \
8
- && rm -rf /var/lib/apt/lists/*
9
 
10
- # Install the pre-built wheel explicitly
11
- RUN pip install --no-cache-dir \
12
- llama-cpp-python \
13
- --extra-index-url https://abetlen.github.io/llama-cpp-python/whl/cpu
14
 
15
- # Install the rest of the app
16
- RUN pip install --no-cache-dir \
17
- huggingface_hub \
18
- gradio
19
 
20
- # Set up the app
 
 
 
21
  WORKDIR /app
22
  COPY . .
23
-
24
- # Launch
25
  CMD ["python", "app.py"]
 
1
+ FROM python:3.10
2
 
3
+ # Download the specific pre-compiled file manually
4
+ RUN wget https://github.com/abetlen/llama-cpp-python/releases/download/v0.2.55/llama_cpp_python-0.2.55-cp310-cp310-linux_x86_64.whl
 
 
 
 
5
 
6
+ # Install the file we just downloaded
7
+ RUN pip install llama_cpp_python-0.2.55-cp310-cp310-linux_x86_64.whl
 
 
8
 
9
+ # Install the rest
10
+ RUN pip install huggingface_hub gradio
 
 
11
 
12
+ # Cleanup
13
+ RUN rm llama_cpp_python-0.2.55-cp310-cp310-linux_x86_64.whl
14
+
15
+ # App Setup
16
  WORKDIR /app
17
  COPY . .
 
 
18
  CMD ["python", "app.py"]