diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile index 33c4cd95b51..5427231cafe 100644 --- a/.devcontainer/Dockerfile +++ b/.devcontainer/Dockerfile @@ -55,9 +55,10 @@ RUN apt-get update \ && go install honnef.co/go/tools/cmd/staticcheck@latest \ && go install golang.org/x/tools/gopls@latest \ # Protocol Buffer Compiler + && PROTOC_VERSION=21.9 \ && if [ $(dpkg --print-architecture) = "amd64" ]; then PROTOC_ARCH="x86_64"; else PROTOC_ARCH="aarch_64" ; fi \ - && curl -LO "https://github.com/protocolbuffers/protobuf/releases/download/v3.20.1/protoc-3.20.1-linux-$PROTOC_ARCH.zip" \ - && unzip "protoc-3.20.1-linux-$PROTOC_ARCH.zip" -d $HOME/.local \ + && curl -LO "https://github.com/protocolbuffers/protobuf/releases/download/v${PROTOC_VERSION}/protoc-${PROTOC_VERSION}-linux-$PROTOC_ARCH.zip" \ + && unzip "protoc-${PROTOC_VERSION}-linux-$PROTOC_ARCH.zip" -d $HOME/.local \ && mv $HOME/.local/bin/protoc /usr/local/bin/protoc \ && mv $HOME/.local/include/ /usr/local/bin/include/ \ && protoc --version \ diff --git a/tools/build-tools.Dockerfile b/tools/build-tools.Dockerfile index 42ac7bc483c..7c94190445c 100644 --- a/tools/build-tools.Dockerfile +++ b/tools/build-tools.Dockerfile @@ -57,3 +57,11 @@ RUN curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | d echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | tee /etc/apt/sources.list.d/github-cli.list > /dev/null && \ apt update && \ apt install -y gh + + # Protocol Buffer Compiler +RUN PROTOC_VERSION=21.9 \ + && if [ $(dpkg --print-architecture) = "amd64" ]; then PROTOC_ARCH="x86_64"; else PROTOC_ARCH="aarch_64" ; fi \ + && curl -LO "https://github.com/protocolbuffers/protobuf/releases/download/v${PROTOC_VERSION}/protoc-${PROTOC_VERSION}-linux-$PROTOC_ARCH.zip" \ + && unzip "protoc-${PROTOC_VERSION}-linux-$PROTOC_ARCH.zip" -d $HOME/.local \ + && mv $HOME/.local/bin/protoc /usr/local/bin/protoc \ + && mv $HOME/.local/include/ /usr/local/bin/include/