diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 173ee8c7..4da85791 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -71,9 +71,10 @@ jobs: uses: actions/download-artifact@v4 with: merge-multiple: true + path: ./dist pattern: ${{ matrix.app }}-${{ matrix.docker-os }}-${{ matrix.docker-arch }} - name: Display artifacts - run: ls -lR . + run: ls -lR ./dist - name: Set up QEMU uses: docker/setup-qemu-action@v3 - name: Set up Docker Buildx @@ -88,7 +89,7 @@ jobs: uses: docker/build-push-action@v5 with: build-args: APP=${{ matrix.app }} - build-contexts: dist-files=. + build-contexts: dist-files=./dist cache-from: type=gha cache-to: type=gha,mode=max file: Dockerfile.release diff --git a/Dockerfile.release b/Dockerfile.release index 17293061..8a92e732 100644 --- a/Dockerfile.release +++ b/Dockerfile.release @@ -12,13 +12,13 @@ FROM --platform=${TARGETPLATFORM} mcr.microsoft.com/windows/nanoserver:ltsc2022 # Use build arguments to select the appropriate binary for Linux FROM linux-base AS linux ARG APP -COPY --from=dist-files ./${APP} /app +COPY --from=dist-files /${APP} /app CMD /app # Use build arguments to select the appropriate binary for Windows FROM windows-base AS windows ARG APP -COPY --from=dist-files ./${APP}.exe /app.exe +COPY --from=dist-files /${APP}.exe /app.exe CMD /app.exe # Final stage: dynamically select between Linux and Windows stages based on TARGETOS argument