-
-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathDockerfile
More file actions
24 lines (16 loc) · 758 Bytes
/
Dockerfile
File metadata and controls
24 lines (16 loc) · 758 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
FROM docker.io/ollama/ollama:latest AS ollama
FROM cgr.dev/chainguard/wolfi-base
# ARG TARGETARCH
RUN apk add --no-cache libstdc++
COPY --from=ollama /usr/bin/ollama /usr/bin/ollama
COPY --from=ollama /usr/lib/ollama/libggml-cpu-* /usr/lib/ollama/
COPY --from=ollama /usr/lib/ollama/libggml-base.so /usr/lib/ollama/libggml-base.so
# In arm64 ollama/ollama image, there is no avx libraries and seems they are not must-have (#2903, #3891)
# COPY --from=ollama /usr/lib/ollama/runners/cpu_avx /usr/lib/ollama/runners/cpu_avx
# COPY --from=ollama /usr/lib/ollama/runners/cpu_avx2 /usr/lib/ollama/runners/cpu_avx2
# Environment variable setup
ENV OLLAMA_HOST=0.0.0.0
# Expose port for the service
EXPOSE 11434
ENTRYPOINT ["/usr/bin/ollama"]
CMD ["serve"]