Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- Dockerfile +11 -6
Dockerfile
CHANGED
|
@@ -1,7 +1,7 @@
|
|
| 1 |
# Builder stage
|
| 2 |
FROM ubuntu:latest
|
| 3 |
|
| 4 |
-
RUN apt update &&
|
| 5 |
|
| 6 |
RUN curl https://ollama.ai/install.sh | sh
|
| 7 |
|
|
@@ -10,11 +10,16 @@ RUN mkdir -p /.ollama && chmod 777 /.ollama
|
|
| 10 |
|
| 11 |
WORKDIR /.ollama
|
| 12 |
|
| 13 |
-
#
|
| 14 |
-
|
|
|
|
| 15 |
|
| 16 |
-
#
|
| 17 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 18 |
|
| 19 |
# Expose the server port
|
| 20 |
-
EXPOSE 7860
|
|
|
|
| 1 |
# Builder stage
|
| 2 |
FROM ubuntu:latest
|
| 3 |
|
| 4 |
+
RUN apt update && apt install curl -y
|
| 5 |
|
| 6 |
RUN curl https://ollama.ai/install.sh | sh
|
| 7 |
|
|
|
|
| 10 |
|
| 11 |
WORKDIR /.ollama
|
| 12 |
|
| 13 |
+
# Copy the entry point script
|
| 14 |
+
COPY entrypoint.sh /entrypoint.sh
|
| 15 |
+
RUN chmod +x /entrypoint.sh
|
| 16 |
|
| 17 |
+
# Set the entry point script as the default command
|
| 18 |
+
ENTRYPOINT ["/entrypoint.sh"]
|
| 19 |
+
CMD ["ollama", "serve"]
|
| 20 |
+
|
| 21 |
+
# Set the model as an environment variable (this can be overridden)
|
| 22 |
+
ENV model=llama2
|
| 23 |
|
| 24 |
# Expose the server port
|
| 25 |
+
EXPOSE 7860
|