Skip to content

Commit

Permalink
[0.8] generated files: use "go install" to install binaries
Browse files Browse the repository at this point in the history
Now that this repository moved to go1.16, we can use 'go install' to install
these binaries.

based on commit bd4b02d
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
  • Loading branch information
thaJeztah committed Sep 2, 2022
1 parent 564380f commit ddf3212
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions hack/dockerfiles/generated-files.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,24 @@

# protoc is dynamically linked to glibc to can't use golang:1.10-alpine
FROM golang:1.13-buster AS gobuild-base
ARG PROTOC_VERSION=3.1.0
ARG GOGO_VERSION=master

RUN apt-get update && apt-get --no-install-recommends install -y \
git \
unzip \
&& true

ARG PROTOC_VERSION=3.1.0
RUN wget -q https://github.com/google/protobuf/releases/download/v${PROTOC_VERSION}/protoc-${PROTOC_VERSION}-linux-x86_64.zip && unzip protoc-${PROTOC_VERSION}-linux-x86_64.zip -d /usr/local

RUN go get -d github.com/gogo/protobuf/protoc-gen-gogofaster \
&& cd /go/src/github.com/gogo/protobuf \
&& git checkout -q $GOGO_VERSION \
&& go install ./protoc-gen-gogo ./protoc-gen-gogofaster ./protoc-gen-gogoslick
ARG GOGO_VERSION=v1.3.2
RUN --mount=target=/root/.cache,type=cache GO111MODULE=on go install \
github.com/gogo/protobuf/protoc-gen-gogo@${GOGO_VERSION} \
github.com/gogo/protobuf/protoc-gen-gogofaster@${GOGO_VERSION} \
github.com/gogo/protobuf/protoc-gen-gogoslick@${GOGO_VERSION}

ARG PROTOBUF_VERSION=v1.3.3
RUN go get -d github.com/golang/protobuf/protoc-gen-go \
&& cd /go/src/github.com/golang/protobuf \
&& git checkout -q $PROTOBUF_VERSION \
&& go install ./protoc-gen-go
RUN --mount=target=/root/.cache,type=cache GO111MODULE=on go install \
github.com/golang/protobuf/protoc-gen-go@${PROTOBUF_VERSION}

WORKDIR /go/src/github.com/moby/buildkit

Expand Down

0 comments on commit ddf3212

Please sign in to comment.