mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-01-18 21:35:24 +01:00
lnrpc: fully dockerize protobuf generation
Remove the need for golang on the host by utilizing golang docker containers to obtain protobuf and grpc gateway versions.
This commit is contained in:
parent
51df3e5b1e
commit
7c7c95e58a
@ -5,8 +5,13 @@ set -e
|
||||
# Directory of the script file, independent of where it's called from.
|
||||
DIR="$(cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd)"
|
||||
|
||||
PROTOBUF_VERSION=$(go list -f '{{.Version}}' -m google.golang.org/protobuf)
|
||||
GRPC_GATEWAY_VERSION=$(go list -f '{{.Version}}' -m github.com/grpc-ecosystem/grpc-gateway/v2)
|
||||
# golang docker image version used in this script.
|
||||
GO_IMAGE=golang:1.19.7-alpine
|
||||
|
||||
PROTOBUF_VERSION=$(docker run --rm -v $DIR/../:/lnd -w /lnd $GO_IMAGE \
|
||||
go list -f '{{.Version}}' -m google.golang.org/protobuf)
|
||||
GRPC_GATEWAY_VERSION=$(docker run --rm -v $DIR/../:/lnd -w /lnd $GO_IMAGE \
|
||||
go list -f '{{.Version}}' -m github.com/grpc-ecosystem/grpc-gateway/v2)
|
||||
|
||||
echo "Building protobuf compiler docker image..."
|
||||
docker build -t lnd-protobuf-builder \
|
||||
|
Loading…
Reference in New Issue
Block a user