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

Commit

Permalink
Decrease docker image size (#1694)
Browse files Browse the repository at this point in the history
* Decrease docker image size

rm commands need to be in the same layer as that adds whatever gets cached or is unneeded. This is because docker layers are append only.

Signed-off-by: Todd Brown <[email protected]>

* Add mkdir back in to dockerfile

Signed-off-by: Todd Brown <[email protected]>
  • Loading branch information
mrbrownt authored and markbates committed Jun 13, 2019
1 parent aff3005 commit 1f0438e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Dockerfile.build
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ RUN go get -u github.com/golang/dep/cmd/dep \
&& go get -v -u github.com/gobuffalo/packr/v2/packr2 \
&& go get -v -u github.com/markbates/filetest \
&& go get -v -u github.com/markbates/grift \
&& go get -v -u github.com/markbates/refresh
&& go get -v -u github.com/markbates/refresh \
&& rm -rfv $GOPATH/src && mkdir -p $BP

RUN curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(go env GOPATH)/bin v1.16.0
# Install golangci
RUN curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(go env GOPATH)/bin v1.16.0

# clear out the src so that we can fill it with new versions
RUN rm -rfv $GOPATH/src && mkdir -p $BP
WORKDIR $BP

ADD go.mod .
Expand Down

0 comments on commit 1f0438e

Please sign in to comment.