diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..c911c1d --- /dev/null +++ b/Dockerfile @@ -0,0 +1,14 @@ +FROM golang:1.22.1-bookworm AS build +WORKDIR /build +COPY main.go ./ +RUN go mod init getjs && \ + go get . && \ + CGO_ENABLED=0 GOOS=linux go build -o getjs + +FROM scratch +WORKDIR /app +COPY --from=build /etc/ssl/certs/ca-certificates.crt \ + /etc/ssl/certs/ca-certificates.crt +COPY --from=build /build/getjs ./ + +ENTRYPOINT ["/app/getjs"] \ No newline at end of file