diff --git a/images/agent/Dockerfile b/images/agent/Dockerfile index 474271d0..30baea95 100644 --- a/images/agent/Dockerfile +++ b/images/agent/Dockerfile @@ -6,7 +6,8 @@ ARG BASE_IMAGE=ghcr.io/spidernet-io/spiderdoctor/agent-base:b381e7abefa471f6e6a3 ARG GOLANG_IMAGE=docker.io/library/golang:1.19 #======= build bin ========== -FROM --platform=${TARGETPLATFORM} ${GOLANG_IMAGE} as builder +# use BUILDPLATFORM to cross build +FROM --platform=${BUILDPLATFORM} ${GOLANG_IMAGE} as builder # docker build var ARG TARGETOS diff --git a/images/controller/Dockerfile b/images/controller/Dockerfile index a00d8cfe..14e138b9 100644 --- a/images/controller/Dockerfile +++ b/images/controller/Dockerfile @@ -6,7 +6,8 @@ ARG BASE_IMAGE=ghcr.io/spidernet-io/spiderdoctor/controller-base:da74ed75a6af16a ARG GOLANG_IMAGE=docker.io/library/golang:1.19 #======= build bin ========== -FROM --platform=${TARGETPLATFORM} ${GOLANG_IMAGE} as builder +# use BUILDPLATFORM to cross build +FROM --platform=${BUILDPLATFORM} ${GOLANG_IMAGE} as builder # docker build var ARG TARGETOS