12 lines
466 B
Docker
12 lines
466 B
Docker
FROM public.ecr.aws/docker/library/golang:1.19-alpine3.17 AS builder
|
|
RUN apk add --no-cache git ca-certificates
|
|
WORKDIR ${GOPATH}/src/github.com/guessi/ssl-certs-checker
|
|
COPY *.go go.mod go.sum ./
|
|
RUN GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -o /go/bin/ssl-certs-checker
|
|
|
|
FROM scratch
|
|
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
|
|
COPY --from=builder /go/bin/ssl-certs-checker /opt/
|
|
WORKDIR /opt/
|
|
ENTRYPOINT ["/opt/ssl-certs-checker"]
|