dnsupdater/Dockerfile
Laurent Le Houerou 14a45cb1de setup go modules
build in docker
build shell script
2019-06-01 21:31:30 +04:00

11 lines
384 B
Docker

FROM golang as builder
WORKDIR /tmp/dnsupdater
COPY . .
RUN go get .
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o dnsupdater .
FROM scratch
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt
COPY --from=builder /usr/share/zoneinfo /usr/share/zoneinfo
COPY --from=builder /tmp/dnsupdater/dnsupdater .
ENTRYPOINT ["/dnsupdater"]