2019-07-25 10:47:02 -04:00
|
|
|
# These options are enabled when running on CI
|
|
|
|
# We do this by copying this file to /etc/bazel.bazelrc at the start of the build.
|
|
|
|
# See documentation in /docs/BAZEL.md
|
|
|
|
|
|
|
|
# Import config items common to both Linux and Windows setups.
|
|
|
|
# https://docs.bazel.build/versions/master/guide.html#bazelrc-syntax-and-semantics
|
2020-01-17 11:03:07 -05:00
|
|
|
try-import %workspace%/.circleci/bazel.common.rc
|
2019-07-25 10:47:02 -04:00
|
|
|
|
|
|
|
# Save downloaded repositories in a location that can be cached by CircleCI. This helps us
|
|
|
|
# speeding up the analysis time significantly with Bazel managed node dependencies on the CI.
|
|
|
|
build --repository_cache=/home/circleci/bazel_repository_cache
|
|
|
|
|
|
|
|
# Workaround https://github.com/bazelbuild/bazel/issues/3645
|
|
|
|
# Bazel doesn't calculate the memory ceiling correctly when running under Docker.
|
|
|
|
# Limit Bazel to consuming resources that fit in CircleCI "xlarge" class
|
|
|
|
# https://circleci.com/docs/2.0/configuration-reference/#resource_class
|
2020-04-06 15:15:05 -04:00
|
|
|
build --local_cpu_resources=8
|
|
|
|
build --local_ram_resources=14336
|
2020-01-17 12:06:48 -05:00
|
|
|
|
|
|
|
# All build executed remotely should be done using our RBE configuration.
|
|
|
|
build:remote --google_default_credentials
|
2020-06-12 15:11:39 -04:00
|
|
|
|
|
|
|
# Upload to GCP's Build Status viewer to allow for us to have better viewing of execution/build
|
|
|
|
# logs. This is only done on CI as the BES (GCP's Build Status viewer) API requires credentials
|
|
|
|
# from service accounts, rather than end user accounts.
|
|
|
|
build:remote --bes_backend=buildeventservice.googleapis.com
|
|
|
|
build:remote --bes_timeout=30s
|
|
|
|
build:remote --bes_results_url="https://source.cloud.google.com/results/invocations/"
|
|
|
|
|
2020-01-17 12:06:48 -05:00
|
|
|
build --config=remote
|