dnscontrol/Dockerfile
Fumihiro Ito f58acabe9f Build: Minimum Go version is now 1.10 (#409)
Can not build by go version under 1.9.
because using the strings.Builder by library.
2018-10-02 10:29:32 -04:00

15 lines
388 B
Docker

FROM golang:1.10-alpine AS build-env
WORKDIR /go/src/github.com/StackExchange/dnscontrol
ADD . .
RUN apk update && apk add git
RUN go run build/build.go -os=linux
RUN cp dnscontrol-Linux /go/bin/dnscontrol
RUN dnscontrol version
FROM alpine
RUN apk add --no-cache ca-certificates
COPY --from=build-env /go/bin/dnscontrol /usr/local/bin
WORKDIR /dns
RUN dnscontrol version
CMD dnscontrol