Support native platform (include linux/arm64)

Signed-off-by: Dorin Geman <dorin.geman@docker.com>
This commit is contained in:
Dorin Geman 2025-04-30 15:28:40 +03:00
parent dbbb7afe9f
commit 596d2f7a94
No known key found for this signature in database
1 changed files with 3 additions and 3 deletions

View File

@ -1,9 +1,9 @@
# Project variables # Project variables
APP_NAME := model-runner APP_NAME := model-runner
GO_VERSION := 1.23.7 GO_VERSION := 1.23.7
LLAMA_SERVER_VERSION := v0.0.4-rc2-cpu LLAMA_SERVER_VERSION := v0.0.4-cpu
TARGET_OS := linux TARGET_OS := linux
TARGET_ARCH := amd64 TARGET_ARCH := $(shell uname -m 2>/dev/null || echo "amd64")
ACCEL := cpu ACCEL := cpu
DOCKER_IMAGE := go-model-runner:latest DOCKER_IMAGE := go-model-runner:latest
LLAMA_BINARY := /com.docker.llama-server.native.$(TARGET_OS).$(ACCEL).$(TARGET_ARCH) LLAMA_BINARY := /com.docker.llama-server.native.$(TARGET_OS).$(ACCEL).$(TARGET_ARCH)
@ -36,7 +36,7 @@ test:
# Build Docker image # Build Docker image
docker-build: docker-build:
docker build --platform linux/amd64 \ docker build \
--build-arg LLAMA_SERVER_VERSION=$(LLAMA_SERVER_VERSION) \ --build-arg LLAMA_SERVER_VERSION=$(LLAMA_SERVER_VERSION) \
--build-arg LLAMA_BINARY_PATH=$(LLAMA_BINARY) \ --build-arg LLAMA_BINARY_PATH=$(LLAMA_BINARY) \
-t $(DOCKER_IMAGE) . -t $(DOCKER_IMAGE) .