aboutsummaryrefslogtreecommitdiffstats
path: root/Dockerfile_distroless
diff options
context:
space:
mode:
Diffstat (limited to 'Dockerfile_distroless')
-rw-r--r--Dockerfile_distroless10
1 files changed, 10 insertions, 0 deletions
diff --git a/Dockerfile_distroless b/Dockerfile_distroless
new file mode 100644
index 0000000..5b7401b
--- /dev/null
+++ b/Dockerfile_distroless
@@ -0,0 +1,10 @@
+FROM golang:1.21 as builder
+WORKDIR /milla
+COPY go.sum go.mod /milla/
+RUN go mod download
+COPY *.go /milla/
+RUN CGO_ENABLED=0 go build
+
+FROM gcr.io/distroless/static-debian12
+COPY --from=builder /milla/milla "/usr/bin/milla"
+ENTRYPOINT ["milla"]