Add binary bake target (#517)

Co-authored-by: CrazyMax <crazy-max@users.noreply.github.com>
This commit is contained in:
CrazyMax
2021-12-09 15:06:43 +01:00
committed by GitHub
parent 7d11524e17
commit 6cac37b603
2 changed files with 10 additions and 1 deletions

View File

@@ -28,12 +28,15 @@ FROM scratch AS artifacts
COPY --from=build /out/*.tar.gz /
COPY --from=build /out/*.zip /
FROM scratch AS binary
COPY --from=build /usr/local/bin/diun* /
FROM alpine:3.14
RUN apk --update --no-cache add \
ca-certificates \
openssl \
&& rm -rf /tmp/* /var/cache/apk/*
&& rm -rf /tmp/*
COPY --from=build /usr/local/bin/diun /usr/local/bin/diun
RUN diun --version

View File

@@ -85,6 +85,12 @@ target "docs" {
output = ["./site"]
}
target "binary" {
inherits = ["_common"]
target = "binary"
output = ["./bin"]
}
target "artifact" {
inherits = ["_common"]
target = "artifacts"