We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 590e0b4 commit 50185f9Copy full SHA for 50185f9
2 files changed
Dockerfile
@@ -0,0 +1,26 @@
1
+FROM golang:1.25 AS builder
2
+
3
+ARG TARGETOS=linux
4
+ARG TARGETARCH=amd64
5
6
+WORKDIR /src
7
8
+COPY go.mod go.sum ./
9
+RUN --mount=type=cache,target=/go/pkg/mod \
10
+ go mod download
11
12
+COPY . .
13
14
15
+ --mount=type=cache,target=/root/.cache/go-build \
16
+ CGO_ENABLED=0 GOOS=${TARGETOS} GOARCH=${TARGETARCH} \
17
+ go build -o /out/mpcium ./cmd/mpcium
18
19
+FROM gcr.io/distroless/base-debian12:latest
20
21
+USER nonroot:nonroot
22
+WORKDIR /app
23
24
+COPY --from=builder /out/mpcium /app/mpcium
25
26
+ENTRYPOINT ["/app/mpcium"]
0 commit comments