mirror of
https://github.com/hanzoai/dev.git
synced 2026-10-25 03:32:32 +00:00
fix(ci): fall back when BuildBuddy key is absent
Make the V8 Bazel workflows use the shared remote BuildBuddy path only when BUILDBUDDY_API_KEY is available, and clear remote/BES settings so the jobs can run locally when the secret is missing.
This commit is contained in:
@@ -114,11 +114,24 @@ jobs:
|
||||
--build_metadata=COMMIT_SHA=$(git rev-parse HEAD)
|
||||
)
|
||||
|
||||
bazel \
|
||||
--noexperimental_remote_repo_contents_cache \
|
||||
--bazelrc=.github/workflows/v8-ci.bazelrc \
|
||||
"${bazel_args[@]}" \
|
||||
"--remote_header=x-buildbuddy-api-key=${BUILDBUDDY_API_KEY}"
|
||||
bazel_flags=(
|
||||
--noexperimental_remote_repo_contents_cache
|
||||
--bazelrc=.github/workflows/v8-ci.bazelrc
|
||||
)
|
||||
|
||||
if [[ -n "${BUILDBUDDY_API_KEY}" ]]; then
|
||||
bazel_flags+=("--remote_header=x-buildbuddy-api-key=${BUILDBUDDY_API_KEY}")
|
||||
else
|
||||
bazel_flags+=(
|
||||
--strategy=local
|
||||
--remote_executor=
|
||||
--remote_cache=
|
||||
--bes_backend=
|
||||
--bes_results_url=
|
||||
)
|
||||
fi
|
||||
|
||||
bazel "${bazel_flags[@]}" "${bazel_args[@]}"
|
||||
|
||||
- name: Stage release pair
|
||||
env:
|
||||
|
||||
@@ -106,11 +106,24 @@ jobs:
|
||||
--build_metadata=COMMIT_SHA=$(git rev-parse HEAD)
|
||||
)
|
||||
|
||||
bazel \
|
||||
--noexperimental_remote_repo_contents_cache \
|
||||
--bazelrc=.github/workflows/v8-ci.bazelrc \
|
||||
"${bazel_args[@]}" \
|
||||
"--remote_header=x-buildbuddy-api-key=${BUILDBUDDY_API_KEY}"
|
||||
bazel_flags=(
|
||||
--noexperimental_remote_repo_contents_cache
|
||||
--bazelrc=.github/workflows/v8-ci.bazelrc
|
||||
)
|
||||
|
||||
if [[ -n "${BUILDBUDDY_API_KEY}" ]]; then
|
||||
bazel_flags+=("--remote_header=x-buildbuddy-api-key=${BUILDBUDDY_API_KEY}")
|
||||
else
|
||||
bazel_flags+=(
|
||||
--strategy=local
|
||||
--remote_executor=
|
||||
--remote_cache=
|
||||
--bes_backend=
|
||||
--bes_results_url=
|
||||
)
|
||||
fi
|
||||
|
||||
bazel "${bazel_flags[@]}" "${bazel_args[@]}"
|
||||
|
||||
- name: Stage release pair
|
||||
env:
|
||||
|
||||
Reference in New Issue
Block a user