build: setup RBE caching and remote build event service on CI (#16370)

This commit is contained in:
Joey Perrott
2019-06-24 14:03:02 -07:00
committed by Jeremy Elbourn
parent 43a01e99c7
commit d511fbea34
3 changed files with 16 additions and 5 deletions
@@ -19,4 +19,11 @@ openssl aes-256-cbc -d -in .circleci/gcp_token -md md5 -k ${GCP_DECRYPT_TOKEN} \
echo "export GOOGLE_APPLICATION_CREDENTIALS=$HOME/.gcp_credentials" >> $BASH_ENV
# Update the CircleCI Bazel configuration to always use remote execution.
echo 'build --config=remote' >> .circleci/bazel.rc
echo "build --config=remote" >> .circleci/bazel.rc
# Only upload locally built results to the cache if we are running already commited code.
if [[ -n "${CIRCLE_PR_NUMBER}" ]]; then
echo "build --remote_upload_local_results=false" >> .circleci/bazel.rc
else
echo "build --remote_upload_local_results=true" >> .circleci/bazel.rc
fi