Skip to content

Commit

Permalink
add certificate authorities
Browse files Browse the repository at this point in the history
  • Loading branch information
mvanholsteijn committed Nov 9, 2021
1 parent 12ac3bb commit 8fcdc94
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
FROM golang:1.17
FROM alpine:3 as ca
RUN apk add --no-cache ca-certificates

FROM golang:1.17 as cru

WORKDIR /cru
ADD . /cru
RUN CGO_ENABLED=0 GOOS=linux go build -ldflags '-extldflags "-static"' .

FROM scratch
COPY --from=0 /cru/cru /
COPY --from=ca /etc/ssl/certs/ /etc/ssl/certs/
COPY --from=cru /cru/cru /
ENTRYPOINT ["/cru"]

0 comments on commit 8fcdc94

Please sign in to comment.