-
Notifications
You must be signed in to change notification settings - Fork 347
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use a remote bazel cache to speed up builds (#153)
Combining disk cache and remote cache with R2, this should speed up tests significantly.
- Loading branch information
Showing
1 changed file
with
35 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
name: Tests | ||
|
||
on: | ||
pull_request: | ||
paths-ignore: | ||
- 'doc/**' | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
test: | ||
strategy: | ||
matrix: | ||
os: [ubuntu-22.04] | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: bazelbuild/setup-bazelisk@v2 | ||
- name: Cache | ||
id: cache | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/bazel-disk-cache | ||
key: ${{ runner.os }}-${{ runner.arch }}-bazel-disk-cache | ||
- run: mkdir -p ~/bazel-disk-cache | ||
- name: install dependencies | ||
if: ${{ runner.os == 'Linux' }} | ||
run: | | ||
export DEBIAN_FRONTEND=noninteractive | ||
sudo apt-get install -y build-essential git clang libc++-dev | ||
- name: bazel tests | ||
run: | | ||
bazel test --remote_timeout=5 --disk_cache=~/bazel-disk-cache --remote_cache=https://bazel:${{ secrets.BAZEL_CACHE_KEY }}@bazel-remote-cache.devprod.workers.dev --verbose_failures --show_timestamps --keep_going --test_output=errors //... | ||