-
Notifications
You must be signed in to change notification settings - Fork 24.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(bazel): use rbe_autoconfig() and new container. (#29336)
After this PR is merged, maintainers no longer need to update .bazelrc file, toolchain and platform related flags for RBE builds and tests (unless there is a breaking change in Bazel related to those flags). Maintainers just need to update the pin of @bazel-toolchains repo regularly in the packages/bazel/package.bzl file according to https://releases.bazel.build/bazel-toolchains.html to include the latest checked-in toolchain configs. If rbe_autoconfig() cannot find appropriate toolchain configs for the version of Bazel in the version of @bazel_toolchains repo that is currently used by this project, it will pull down the container and generate the configs on the fly as the beginning of the build/test. PR Close #29336
- Loading branch information
Showing
8 changed files
with
93 additions
and
263 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
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
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
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
50 changes: 50 additions & 0 deletions
50
third_party/github.com/bazelbuild/bazel-toolchains/bazelrc/.bazelrc.notoolchain
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,50 @@ | ||
# Copyright 2016 The Bazel Authors. All rights reserved. | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# This .bazelrc file contains some of the flags required for the provided | ||
# toolchain with Remote Build Execution. Specifically, it includes all flags | ||
# except toolchain/platform flags. | ||
|
||
# Depending on how many machines are in the remote execution instance, setting | ||
# this higher can make builds faster by allowing more jobs to run in parallel. | ||
# Setting it too high can result in jobs that timeout, however, while waiting | ||
# for a remote machine to execute them. | ||
build:remote --jobs=50 | ||
|
||
# Set various strategies so that all actions execute remotely. Mixing remote | ||
# and local execution will lead to errors unless the toolchain and remote | ||
# machine exactly match the host machine. | ||
build:remote --spawn_strategy=remote | ||
build:remote --strategy=Javac=remote | ||
build:remote --strategy=Closure=remote | ||
build:remote --strategy=Genrule=remote | ||
build:remote --define=EXECUTOR=remote | ||
|
||
# Enable the remote cache so action results can be shared across machines, | ||
# developers, and workspaces. | ||
build:remote --remote_cache=remotebuildexecution.googleapis.com | ||
|
||
# Enable remote execution so actions are performed on the remote systems. | ||
build:remote --remote_executor=remotebuildexecution.googleapis.com | ||
|
||
# Enable encryption. | ||
build:remote --tls_enabled=true | ||
|
||
# Set a higher timeout value, just in case. | ||
build:remote --remote_timeout=3600 | ||
|
||
# Enable authentication. This will pick up application default credentials by | ||
# default. You can use --auth_credentials=some_file.json to use a service | ||
# account credential instead. | ||
build:remote --auth_enabled=true |
127 changes: 0 additions & 127 deletions
127
third_party/github.com/bazelbuild/bazel-toolchains/bazelrc/bazel-0.21.0.bazelrc
This file was deleted.
Oops, something went wrong.
106 changes: 0 additions & 106 deletions
106
third_party/github.com/bazelbuild/bazel-toolchains/bazelrc/bazel-0.24.0.bazelrc
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.