Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- Dockerfile +5 -5
Dockerfile
CHANGED
@@ -13,10 +13,10 @@ ENV HOME=/home/user \
|
|
13 |
PATH=/home/user/.local/bin:$PATH \
|
14 |
OLLAMA_HOST=0.0.0.0 \
|
15 |
OLLAMA_ORIGINS=* \
|
16 |
-
# ==> FIX: Point Ollama's entire
|
17 |
OLLAMA_ROOT=/tmp/ollama
|
18 |
|
19 |
-
#
|
20 |
RUN mkdir -p $OLLAMA_ROOT && \
|
21 |
chown -R user:user $OLLAMA_ROOT
|
22 |
|
@@ -24,11 +24,11 @@ RUN mkdir -p $OLLAMA_ROOT && \
|
|
24 |
WORKDIR $HOME/app
|
25 |
USER user
|
26 |
|
27 |
-
# Copy
|
28 |
-
COPY --chown=user:user entrypoint.sh
|
29 |
|
30 |
# Make the entrypoint script executable
|
31 |
-
RUN chmod +x
|
32 |
|
33 |
# Expose the port for the Ollama server
|
34 |
EXPOSE 11434
|
|
|
13 |
PATH=/home/user/.local/bin:$PATH \
|
14 |
OLLAMA_HOST=0.0.0.0 \
|
15 |
OLLAMA_ORIGINS=* \
|
16 |
+
# ==> FIX: Point Ollama's entire root to the writable /tmp directory
|
17 |
OLLAMA_ROOT=/tmp/ollama
|
18 |
|
19 |
+
# Create the new root directory and give the 'user' ownership
|
20 |
RUN mkdir -p $OLLAMA_ROOT && \
|
21 |
chown -R user:user $OLLAMA_ROOT
|
22 |
|
|
|
24 |
WORKDIR $HOME/app
|
25 |
USER user
|
26 |
|
27 |
+
# Copy your entrypoint script
|
28 |
+
COPY --chown=user:user entrypoint.sh .
|
29 |
|
30 |
# Make the entrypoint script executable
|
31 |
+
RUN chmod +x ./entrypoint.sh
|
32 |
|
33 |
# Expose the port for the Ollama server
|
34 |
EXPOSE 11434
|