diff options
| author | unitexe <unitexe70@gmail.com> | 2026-02-26 18:15:06 -0600 |
|---|---|---|
| committer | unitexe <unitexe70@gmail.com> | 2026-02-26 18:22:42 -0600 |
| commit | d8ac23f9082a879c259c5d6ff6a2544041f5adad (patch) | |
| tree | 611ba2edd2d34ded403ca109b5ed3be5d99f74b1 /Containerfile | |
Diffstat (limited to 'Containerfile')
| -rw-r--r-- | Containerfile | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/Containerfile b/Containerfile new file mode 100644 index 0000000..3e5cac2 --- /dev/null +++ b/Containerfile @@ -0,0 +1,28 @@ +# +# Build (fetch) stage +# + +FROM alpine AS fetch + +ARG TARGETARCH +ARG TARGETVARIANT +ARG VERSION + +RUN echo "TARGETARCH=${TARGETARCH} TARGETVARIANT=${TARGETVARIANT}" +RUN apk add --no-cache wget tar \ + && ARCH=$(uname -m) \ + && case "${ARCH}" in \ + x86_64) GRPC_ARCH="x86_64" ;; \ + aarch64) GRPC_ARCH="arm64" ;; \ + armv7l) GRPC_ARCH="armv7" ;; \ + esac \ + && wget -q https://github.com/fullstorydev/grpcurl/releases/download/v${VERSION}/grpcurl_${VERSION}_linux_${GRPC_ARCH}.tar.gz \ + && tar --no-same-owner -xzf grpcurl_${VERSION}_linux_${GRPC_ARCH}.tar.gz + +# +# Run stage +# + +FROM scratch +COPY --from=fetch /grpcurl /grpcurl +ENTRYPOINT ["/grpcurl"] |
