Files
kaspad/docker/Dockerfile.dev
stasatdaglabs 194ceace6f [NOD-71] Add support for Go modules (#251)
* [NOD-71] Replaced Gopkg.lock and Gopkg.toml with go.mod and go.sum.

* [NOD-71] Updated Dockerfiles to use go-modules instead of dep.
2019-04-17 13:45:29 +03:00

24 lines
610 B
Docker

FROM golang:1.12-alpine
ENV PATH="${GOPATH}/bin:${PATH}"
RUN mkdir -p /go/src/github.com/daglabs/btcd
WORKDIR /go/src/github.com/daglabs/btcd
RUN apk add --no-cache curl git openssh binutils gcc musl-dev tini bash
# Allow delve to run on Alpine based containers.
RUN apk add --no-cache libc6-compat
RUN go get github.com/derekparker/delve/cmd/dlv
COPY . .
# GO111MODULE=on forces Go to use the go-module system
# TODO: remove this once Go 1.13 is released
ENV GO111MODULE=on
RUN CGO_ENABLED=0 GOOS=linux go build -gcflags "all=-N -l" -a -installsuffix cgo -o btcd .
ENTRYPOINT [ "/sbin/tini", "--" ]