From b768dc37bf0d24298beceb26d73354acc6b591bd Mon Sep 17 00:00:00 2001 From: yedf2 <120050102@qq.com> Date: Sat, 23 Sep 2023 22:02:17 +0800 Subject: [PATCH] update --- helper/Dockerfile-release | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/helper/Dockerfile-release b/helper/Dockerfile-release index 224dc52..e932b93 100644 --- a/helper/Dockerfile-release +++ b/helper/Dockerfile-release @@ -5,7 +5,7 @@ # COPY . . # RUN cd admin && yarn && VITE_ADMIN_VERSION=$RELEASE_VERSION yarn build -FROM --platform=$TARGETPLATFORM golang:1.18-alpine as builder2 +FROM --platform=$TARGETPLATFORM golang:1.18-alpine as builder1 ARG TARGETARCH ARG TARGETOS ARG RELEASE_VERSION @@ -14,7 +14,7 @@ WORKDIR /app/dtm COPY . . RUN CGO_ENABLED=0 GOOS=$TARGETOS GOARCH=$TARGETARCH go build -ldflags="-s -w -X main.Version=$RELEASE_VERSION" -FROM --platform=amd64 node as builder1 +FROM --platform=amd64 node as builder2 ARG TARGETARCH ARG TARGETOS ARG RELEASE_VERSION @@ -23,7 +23,7 @@ COPY . . RUN cd admin && npm install -g yarn && yarn && VITE_ADMIN_VERSION=$RELEASE_VERSION yarn build FROM --platform=$TARGETPLATFORM alpine -COPY --from=builder2 /app/dtm/dtm /app/dtm/ +COPY --from=builder1 /app/dtm/dtm /app/dtm/ COPY --from=builder2 /app/dtm/admin/index.html /app/dtm/admin/ COPY --from=builder2 /app/dtm/admin/dist /app/dtm/admin/ WORKDIR /app/dtm