Skip to content
This repository has been archived by the owner on Oct 17, 2024. It is now read-only.

Commit

Permalink
Merge pull request #128 from heetch/004-fix-dockerfile
Browse files Browse the repository at this point in the history
Fix Dockerfile to work with modules
  • Loading branch information
rogpeppe authored Sep 11, 2019
2 parents f4f87a3 + 2df9a07 commit 31ac6c5
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
FROM golang:1.12-alpine as builder
FROM golang:1.13-alpine as builder

ADD https://github.com/golang/dep/releases/download/v0.5.0/dep-linux-amd64 /usr/bin/dep
RUN chmod +x /usr/bin/dep
RUN apk --no-cache --update add git
WORKDIR $GOPATH/src/github.com/heetch/regula
COPY Gopkg.toml Gopkg.lock ./
RUN dep ensure --vendor-only
COPY . ./
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -a -installsuffix cgo -o /regula ./cmd/regula
WORKDIR /src/regula
COPY . .
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -a -o /regula ./cmd/regula
RUN chmod +x /regula
CMD ["/regula"]

Expand Down

0 comments on commit 31ac6c5

Please sign in to comment.