Skip to content

Build //src/... with nativelink #663

Build //src/... with nativelink

Build //src/... with nativelink #663

name: Build //src/... with nativelink
on:
push:
workflow_dispatch:
workflow_call:
workflow_run:
workflows: ["rebase upstream manual", "rebase upstream cron"]
types:
- completed
jobs:
linux-build:
runs-on: large-ubuntu-22.04
steps:
- name: Checkout
uses: >- # v4.1.1
actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- name: Setup Bazelisk
uses: >- # v0.8.1
bazel-contrib/setup-bazel@b388b84bb637e50cdae241d0f255670d4bd79f29
- name: Build mongodb
run: |-
echo "--config=nativelink
# Remote execution / Cache settings
build:nativelink --remote_executor=scheduler-mongo-ci-dev.dev-usw2.nativelink.net:443
build:nativelink --remote_cache=cas-mongo-ci-dev.dev-usw2.nativelink.net:443
build:nativelink --remote_header=x-nativelink-api-key=$NATIVELINK_HEADER_RW_KEY
# TODO(adams): paramterize over this value after reverting the execution properties changes.
build:nativelink --remote_default_exec_properties="container-image=docker://ubuntu22:latest"
build:nativelink --remote_instance_name=main
build:nativelink --remote_download_minimal
build:nativelink --remote_timeout=600
# BES settings
build:nativelink --bes_backend=grpcs://bes-mongo-ci-dev.dev-usw2.nativelink.net
build:nativelink --bes_header=x-nativelink-api-key=$NATIVELINK_HEADER_RW_KEY
build:nativelink --bes_results_url=https://dev.nativelink.com/a/tracemachina/build
# Nativelink does not support, disabled for now.
build:nativelink --experimental_remote_cache_compression=false
# Number of bazel jobs to run
build:nativelink --jobs 500
# Debug logging settings
# build:nativelink --remote_grpc_log=/tmp/grpc.log
# build:nativelink --execution_log_json_file=/tmp/execution.log
# build:nativelink --build_event_json_file=/tmp/build_events.json
# build:nativelink --verbose_failures
# build:nativelink -s
# build:nativelink --platform_suffix=c2
build:nativelink --remote_print_execution_messages=all
" > .bazelrc.local
bazel build //src/... --config=nativelink
env:
NATIVELINK_HEADER_RW_KEY: ${{ secrets.NATIVELINK_HEADER_RW_KEY }}