Skip to content

Commit 0130eb6

Browse files
author
Piotr Stankiewicz
committed
Prepare Docker file ahead of multi-backend builds of llama-server
llama.cpp can be built to support multiple variants of the CPU backend, and choose the best one at runtime. This requires a dynamically linked build of the llama-server. So modify the model-runner Docker file to play nice with such builds of the llama-server. Signed-off-by: Piotr Stankiewicz <[email protected]>
1 parent 5047eed commit 0130eb6

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ COPY --from=builder /app/model-runner /app/model-runner
5353

5454
# Copy the llama.cpp binary from the llama-server stage
5555
ARG LLAMA_BINARY_PATH
56-
COPY --from=llama-server ${LLAMA_BINARY_PATH}/bin/com.docker.llama-server /app/bin/com.docker.llama-server
56+
COPY --from=llama-server ${LLAMA_BINARY_PATH}/ /app/.
5757
RUN chmod +x /app/bin/com.docker.llama-server
5858

5959
USER modelrunner
@@ -64,6 +64,7 @@ ENV MODEL_RUNNER_PORT=12434
6464
ENV LLAMA_SERVER_PATH=/app/bin
6565
ENV HOME=/home/modelrunner
6666
ENV MODELS_PATH=/models
67+
ENV LD_LIBRARY_PATH=/app/lib
6768

6869
# Label the image so that it's hidden on cloud engines.
6970
LABEL com.docker.desktop.service="model-runner"

0 commit comments

Comments
 (0)