fix: add ldflags for version, remove privileged, enable flash attention
This commit is contained in:
@@ -63,7 +63,6 @@ services:
|
|||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
image: ollama/ollama:rocm-gfx906
|
image: ollama/ollama:rocm-gfx906
|
||||||
container_name: ollama
|
container_name: ollama
|
||||||
privileged: true
|
|
||||||
tty: true
|
tty: true
|
||||||
restart: always
|
restart: always
|
||||||
ports:
|
ports:
|
||||||
@@ -81,7 +80,7 @@ services:
|
|||||||
- HSA_ENABLE_SDMA=0
|
- HSA_ENABLE_SDMA=0
|
||||||
- OLLAMA_HOST=0.0.0.0
|
- OLLAMA_HOST=0.0.0.0
|
||||||
- OLLAMA_DEBUG=1
|
- OLLAMA_DEBUG=1
|
||||||
- OLLAMA_FLASH_ATTENTION=0
|
- OLLAMA_FLASH_ATTENTION=1
|
||||||
- OLLAMA_NUM_PARALLEL=2
|
- OLLAMA_NUM_PARALLEL=2
|
||||||
devices:
|
devices:
|
||||||
# Map the render nodes and KFD for ROCm to work inside the container
|
# Map the render nodes and KFD for ROCm to work inside the container
|
||||||
|
|||||||
@@ -74,7 +74,7 @@ RUN mkdir -p build-hip && \
|
|||||||
|
|
||||||
# Step 3: Build Go binary (GCC for CGo linking)
|
# Step 3: Build Go binary (GCC for CGo linking)
|
||||||
ENV CGO_ENABLED=1
|
ENV CGO_ENABLED=1
|
||||||
RUN go build -trimpath -o /build/dist/ollama .
|
RUN go build -trimpath -ldflags="-X=github.com/ollama/ollama/version.Version=${OLLAMA_VERSION}" -o /build/dist/ollama .
|
||||||
|
|
||||||
# ---------- Runtime image ----------
|
# ---------- Runtime image ----------
|
||||||
FROM ubuntu:24.04
|
FROM ubuntu:24.04
|
||||||
|
|||||||
Reference in New Issue
Block a user