diff options
author | Alvaro Vilaplana Garcia <alvaro.vilaplana@gmail.com> | 2023-11-15 15:59:25 +0000 |
---|---|---|
committer | Álvaro Vilaplana García <alvaro.vilaplana@gmail.com> | 2024-02-07 10:14:42 +0000 |
commit | 78f452478b147e3478dfe8cf4c1ce85511fe10eb (patch) | |
tree | 577350943eb711ab8645665f9b977a06ccd845c5 | |
parent | 711f1d5e039abe7435b0ed5ca91616268b850b47 (diff) |
Bazel: Add support for BuildBuddy RBE provider
This changes add support for a new RBE provider. BuildBuddy
provides an open-core suite of enterprise features for Bazel.
Included are a Remote Build Execution service, a shared build
artifact cache, and a build result UI. It's available as a
fully-managed cloud service or as an easy to deploy on-prem
solution. The service is free to use for individuals and
open-source projects.
To initiate a build using BuildBuddy RBE, run the following
command:
$ bazel build --config=remote_bb \
--remote_instance_name=${PROJECT} \
--remote_header=x-buildbuddy-api-key=YOUR_API_KEY \
release
Release-Notes: Bazel: Add support for BuildBuddy RBE provider
Change-Id: I92f22b9eec749e2d151c54e4f5b9476d116ec958
-rw-r--r-- | .bazelrc | 8 | ||||
-rw-r--r-- | Documentation/dev-bazel.txt | 15 | ||||
-rw-r--r-- | tools/remote-bazelrc | 20 |
3 files changed, 43 insertions, 0 deletions
@@ -24,6 +24,10 @@ build:remote --config=build_shared # Define remote configuration alias build:remote_gcp --config=remote +# Builds and executes on BuildBuddy RBE using remotejdk_11 +build:remote_bb --config=config_bb +build:remote_bb --config=build_shared + # Define configuration using remotejdk_17, executes using remotejdk_17 or local_jdk build:build_java17_shared --java_language_version=17 build:build_java17_shared --java_runtime_version=remotejdk_17 @@ -39,6 +43,10 @@ build:remote17 --config=build_java17_shared # Define remote17 configuration alias build:remote17_gcp --config=remote17 +# Builds and executes on BuildBuddy RBE using remotejdk_17 +build:remote17_bb --config=config_bb +build:remote17_bb --config=build_java17_shared + # Enable strict_action_env flag to. For more information on this feature see # https://groups.google.com/forum/#!topic/bazel-discuss/_VmRfMyyHBk. # This will be the new default behavior at some point (and the flag was flipped diff --git a/Documentation/dev-bazel.txt b/Documentation/dev-bazel.txt index a2bd6fca6e..893d28a63f 100644 --- a/Documentation/dev-bazel.txt +++ b/Documentation/dev-bazel.txt @@ -663,6 +663,21 @@ bazel test --config=remote \ ``` +== BuildBuddy Remote Build Support + +To utilize the BuildBuddy Remote Build Execution service, please consult the +documentation available at the following link: https://www.buildbuddy.io[BuildBuddy]. + +To use RBE, execute + +``` +bazelisk test --config=remote_bb \ + --remote_instance_name=projects/${PROJECT}/instances/default_instance \ + --remote_header=x-buildbuddy-api-key=YOUR_API_KEY \ + javatests/... +``` + + GERRIT ------ Part of link:index.html[Gerrit Code Review] diff --git a/tools/remote-bazelrc b/tools/remote-bazelrc index 417b2e8758..d8da574151 100644 --- a/tools/remote-bazelrc +++ b/tools/remote-bazelrc @@ -59,3 +59,23 @@ build:config_gcp --remote_executor=remotebuildexecution.googleapis.com # account credential instead. build:config_gcp --google_default_credentials build:config_gcp --config=remote_shared + +# Configuration flags for remote settings in BuildBuddy RBE +# Enable the remote cache so action results can be shared across machines, +# developers, and workspaces. +build:config_bb --remote_cache=grpcs://remote.buildbuddy.io + +# Enable remote execution so actions are performed on the remote systems. +build:config_bb --remote_executor=grpcs://remote.buildbuddy.io + +# The results from each Bazel command are viewable with BuildBuddy +build:config_bb --bes_results_url=https://app.buildbuddy.io/invocation/ + +# The results of a local build will be uploaded to the BuildBuddy server, +# providing visibility and collaboration features for the build. +build:config_bb --remote_upload_local_results + +# Define the Build Event Service (BES) backend to use for remote caching and +# build event storage. +build:config_bb --bes_backend=grpcs://remote.buildbuddy.io +build:config_bb --config=remote_shared |