Spaces:
Build error
Build error
Update Dockerfile
Browse files- Dockerfile +4 -4
Dockerfile
CHANGED
|
@@ -6,14 +6,14 @@ RUN apt update && apt install -y curl git python3 python3-pip
|
|
| 6 |
# Install Ollama
|
| 7 |
RUN curl -fsSL https://ollama.com/install.sh | sh
|
| 8 |
|
| 9 |
-
#
|
| 10 |
-
RUN ollama pull llama3.2:3b-instruct-fp16
|
| 11 |
|
| 12 |
# Install Python dependencies
|
| 13 |
-
RUN pip install langchain langchain_ollama
|
| 14 |
|
| 15 |
# Expose Ollama API port
|
| 16 |
EXPOSE 11434
|
| 17 |
|
| 18 |
-
#
|
| 19 |
CMD ["ollama", "serve"]
|
|
|
|
| 6 |
# Install Ollama
|
| 7 |
RUN curl -fsSL https://ollama.com/install.sh | sh
|
| 8 |
|
| 9 |
+
# Start Ollama server in the background and pull the model
|
| 10 |
+
RUN ollama serve & sleep 5 && ollama pull llama3.2:3b-instruct-fp16
|
| 11 |
|
| 12 |
# Install Python dependencies
|
| 13 |
+
RUN pip install langchain langchain_ollama ollama
|
| 14 |
|
| 15 |
# Expose Ollama API port
|
| 16 |
EXPOSE 11434
|
| 17 |
|
| 18 |
+
# Start Ollama on container startup
|
| 19 |
CMD ["ollama", "serve"]
|