Skip to content

Commit

Permalink
fix(docker): optimize dockerfile with GOPROXY
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanswrt committed Nov 6, 2020
1 parent f9e1ec2 commit 2e4655a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,17 @@ RUN git config --global url."https://${GITHUB_TOKEN}:x-oauth-basic@github.com/".

# Mark private repositories
ENV GOPRIVATE=github.com/renproject/darknode
ENV GOPROXY=https://proxy.golang.org

# Download dependencies.
WORKDIR /lightnode
COPY go.mod .
COPY go.sum .
RUN go mod edit -replace=github.com/filecoin-project/filecoin-ffi=$(go env GOPATH)/src/github.com/filecoin-project/filecoin-ffi
RUN go mod download

# Copy the code into the container.
COPY . .
RUN go mod edit -replace=github.com/filecoin-project/filecoin-ffi=$(go env GOPATH)/src/github.com/filecoin-project/filecoin-ffi

# Build the code inside the container.
RUN go build ./cmd/lightnode
Expand Down

0 comments on commit 2e4655a

Please sign in to comment.