Skip to content

Commit 3ae58c4

Browse files
committed
ci: Add protoc compiler to setup
1 parent f63ec15 commit 3ae58c4

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

.github/scripts/setup.sh

+12
Original file line numberDiff line numberDiff line change
@@ -71,3 +71,15 @@ sudo chmod 0440 /etc/sudoers.d/tester
7171

7272
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- \
7373
-y --default-toolchain ${RUST_VERSION}
74+
75+
# We also need a relatively recent protobuf-compiler, at least 3.12.0,
76+
# in order to support the experimental `optional` flag.
77+
PROTOC_VERSION=3.15.8
78+
PB_REL="https://github.com/protocolbuffers/protobuf/releases"
79+
curl -LO $PB_REL/download/v${PROTOC_VERSION}/protoc-${PROTOC_VERSION}-linux-x86_64.zip
80+
sudo unzip protoc-3.15.8-linux-x86_64.zip -d /usr/local/
81+
sudo chmod a+x /usr/local/bin/protoc
82+
export PROTOC=/usr/local/bin/protoc
83+
export PATH=$PATH:/usr/local/bin
84+
env
85+
ls -lha /usr/local/bin

.github/workflows/ci.yaml

+3
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ on:
55
branches:
66
- "master"
77
pull_request:
8+
89
jobs:
910
smoke-test:
1011
name: Smoke Test ${{ matrix.cfg }}
@@ -61,6 +62,8 @@ jobs:
6162
TEST_GROUP_COUNT: ${{ matrix.TEST_GROUP_COUNT }}
6263
TEST_GROUP: ${{ matrix.TEST_GROUP }}
6364
run: |
65+
echo $PROTOC
66+
which protoc
6467
bash -x .github/scripts/build.sh
6568
6669
- name: Upload Unit Test Results

0 commit comments

Comments
 (0)