From ee76cd3f3668809512557d7864fcf4b2b6191695 Mon Sep 17 00:00:00 2001 From: yyg-max <175597134+yyg-max@users.noreply.github.com> Date: Tue, 30 Sep 2025 11:37:10 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=E5=87=8F=E5=B0=91=E9=95=9C?= =?UTF-8?q?=E5=83=8F=E5=86=85=E5=AD=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Dockerfile | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index 90b7d63..d2275a0 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,12 +10,8 @@ WORKDIR /app # set build arg for platform ARG TARGETPLATFORM -# copy all binaries into image -COPY cdk-server-amd64 . -COPY cdk-server-arm64 . - -# select binary according to platform -RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then cp cdk-server-amd64 cdk-server; elif [ "$TARGETPLATFORM" = "linux/arm64" ]; then cp cdk-server-arm64 cdk-server; fi +# copy the appropriate binary based on platform +COPY cdk-server-${TARGETPLATFORM#linux/} ./cdk-server # copy docs and support files COPY docs ./docs