File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -193,7 +193,7 @@ check-protoc:
193193 fi
194194
195195install-protoc install-protobuf :
196- $(Q ) PROTOBUF_VERSION=$(PROTOBUF_VERSION ) ./scripts/install-protobuf
196+ $(Q ) PROTOBUF_VERSION=$(PROTOBUF_VERSION ) INSTALL_DIR= $( PROTOC_PATH ) ./scripts/install-protobuf
197197
198198clean-protoc :
199199 $(Q ) rm -rf $(PROTOC_PATH )
Original file line number Diff line number Diff line change @@ -23,12 +23,9 @@ WORKDIR /go/src
2323RUN apt-get update && apt-get install -y unzip
2424
2525RUN --mount=type=cache,target=/go/pkg/mod/ \
26- --mount=src=.,target=. \
27- make install-protoc-dependencies install-ttrpc-plugin install-wasm-plugin install-protoc
28-
29- RUN --mount=type=cache,target=/go/pkg/mod/ \
26+ --mount=type=cache,target=/go/tools/,sharing=private \
3027 --mount=src=.,target=.,rw=true \
31- make build-proto && \
28+ make build-proto PROTOC_PATH=/go/tools/protoc && \
3229 tar czf /artifacts.tgz ${ARTIFACTS}
3330
3431FROM scratch AS final
Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ PROTOBUF_VERSION=${PROTOBUF_VERSION-3.20.1}
2424GOARCH=$( go env GOARCH)
2525GOOS=$( go env GOOS)
2626PROTOBUF_DIR=$( mktemp -d)
27- INSTALL_DIR=" $PWD /build/tools/protoc"
27+ INSTALL_DIR=${INSTALL_DIR- " $PWD /build/tools/protoc" }
2828
2929mkdir -p " $INSTALL_DIR "
3030
You can’t perform that action at this time.
0 commit comments