mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-05-02 14:26:23 -04:00
bazel: use remote caching (#1456)
* bazel: add configuration for remote caching * ci: enable bazel remote caching for building binaries * ci: use bazel directly when building go binaries * ci: enable cache for most build steps * dev-docs: document remote caching
This commit is contained in:
parent
4f37fe38f9
commit
c3c0940adb
20 changed files with 263 additions and 46 deletions
|
@ -50,6 +50,17 @@ bazel build //cli:cli_oss_darwin_amd64 # cross compile CLI for mac amd64
|
|||
bazel build //cli:cli_oss_darwin_arm64 # cross compile CLI for mac arm64
|
||||
```
|
||||
|
||||
## Remote caching and execution
|
||||
|
||||
We use BuildBuddy for remote caching (and maybe remote execution in the future). To use it, you need to join the BuildBuddy organization and get an API key. Then, you can write it to `~/.bazelrc`:
|
||||
|
||||
```
|
||||
build --remote_header=x-buildbuddy-api-key=<redacted>
|
||||
```
|
||||
|
||||
To use the remote cache, build the project with `bazel build --config remote_cache //path/to:target`.
|
||||
You can also copy the `remote_cache` config from `.bazelrc` to your `~/.bazelrc` and remove the `remote_cache` prefix to make it the default.
|
||||
|
||||
# Test
|
||||
|
||||
You can run all integration and unitttests like this:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue