From 3e3a6fb211e42a26715fc81d274ba61f725bd05b Mon Sep 17 00:00:00 2001 From: "trop[bot]" <37223003+trop[bot]@users.noreply.github.com> Date: Thu, 17 Oct 2024 13:36:13 -0400 Subject: [PATCH] chore: fixup reclient read only access on forks (#44303) Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: John Kleinschmidt --- .github/actions/install-build-tools/action.yml | 2 +- .../workflows/pipeline-segment-electron-build.yml | 13 ++----------- .../pipeline-segment-electron-gn-check.yml | 2 +- appveyor-woa.yml | 4 +--- appveyor.yml | 4 +--- 5 files changed, 6 insertions(+), 19 deletions(-) diff --git a/.github/actions/install-build-tools/action.yml b/.github/actions/install-build-tools/action.yml index e9f757430fe..79628bf6836 100644 --- a/.github/actions/install-build-tools/action.yml +++ b/.github/actions/install-build-tools/action.yml @@ -6,6 +6,6 @@ runs: - name: Install Build Tools shell: bash run: | - export BUILD_TOOLS_SHA=33dc5186556bfbf7b0121a00cdd89ed3802e47da + export BUILD_TOOLS_SHA=eeb1a11392e4cec08fd926c93b31ab556dc0c23b npm i -g @electron/build-tools e auto-update disable diff --git a/.github/workflows/pipeline-segment-electron-build.yml b/.github/workflows/pipeline-segment-electron-build.yml index 96ddf610452..32983a91d0f 100644 --- a/.github/workflows/pipeline-segment-electron-build.yml +++ b/.github/workflows/pipeline-segment-electron-build.yml @@ -164,7 +164,7 @@ jobs: uses: ./src/electron/.github/actions/install-build-tools - name: Init Build Tools run: | - e init -f --root=$(pwd) --out=Default ${{ inputs.gn-build-type }} --import ${{ inputs.gn-build-type }} --target-cpu ${{ inputs.target-arch }} --only-sdk + e init -f --root=$(pwd) --out=Default ${{ inputs.gn-build-type }} --import ${{ inputs.gn-build-type }} --target-cpu ${{ inputs.target-arch }} - name: Run Electron Only Hooks run: | gclient runhooks --spec="solutions=[{'name':'src/electron','url':None,'deps_file':'DEPS','custom_vars':{'process_deps':False},'managed':False}]" @@ -177,18 +177,9 @@ jobs: - name: Fix Sync (macOS) if: ${{ inputs.target-platform == 'macos' }} uses: ./src/electron/.github/actions/fix-sync-macos - - name: Install build-tools & Setup RBE + - name: Setup Number of Ninja Processes run: | echo "NUMBER_OF_NINJA_PROCESSES=${{ inputs.target-platform == 'linux' && '300' || '200' }}" >> $GITHUB_ENV - cd ~/.electron_build_tools - npx yarn --ignore-engines - # Pull down credential helper and print status - node -e "require('./src/utils/reclient.js').downloadAndPrepare({})" - HELPER=$(node -p "require('./src/utils/reclient.js').helperPath({})") - $HELPER login - echo 'RBE_service='`node -e "console.log(require('./src/utils/reclient.js').serviceAddress)"` >> $GITHUB_ENV - echo 'RBE_credentials_helper='`node -e "console.log(require('./src/utils/reclient.js').helperPath({}))"` >> $GITHUB_ENV - echo 'RBE_credentials_helper_args=print' >> $GITHUB_ENV - name: Free up space (macOS) if: ${{ inputs.target-platform == 'macos' }} uses: ./src/electron/.github/actions/free-space-macos diff --git a/.github/workflows/pipeline-segment-electron-gn-check.yml b/.github/workflows/pipeline-segment-electron-gn-check.yml index db2f288aee7..4978e227a48 100644 --- a/.github/workflows/pipeline-segment-electron-gn-check.yml +++ b/.github/workflows/pipeline-segment-electron-gn-check.yml @@ -75,7 +75,7 @@ jobs: uses: ./src/electron/.github/actions/install-build-tools - name: Init Build Tools run: | - e init -f --root=$(pwd) --out=Default ${{ inputs.gn-build-type }} --import ${{ inputs.gn-build-type }} --target-cpu ${{ inputs.target-arch }} --only-sdk + e init -f --root=$(pwd) --out=Default ${{ inputs.gn-build-type }} --import ${{ inputs.gn-build-type }} --target-cpu ${{ inputs.target-arch }} - name: Get Depot Tools timeout-minutes: 5 run: | diff --git a/appveyor-woa.yml b/appveyor-woa.yml index bc91f308152..eb6e8496f7b 100644 --- a/appveyor-woa.yml +++ b/appveyor-woa.yml @@ -128,8 +128,6 @@ for: if ($env:ELECTRON_RBE_JWT -eq '') { $env:RBE_fail_early_min_action_count = "0" $env:RBE_fail_early_min_fallback_ratio = "0" - $env:RBE_exec_strategy = "local" - $env:RBE_remote_update_cache= "false" } - cd ..\.. - ps: $env:CHROMIUM_BUILDTOOLS_PATH="$pwd\src\buildtools" @@ -158,7 +156,7 @@ for: - gn check out/Default //electron:electron_app - gn check out/Default //electron/shell/common:mojo - gn check out/Default //electron/shell/common:plugin - - if DEFINED ELECTRON_RBE_JWT (autoninja -j 300 -C out/Default electron:electron_app) else (autoninja -C out/Default electron:electron_app) + - autoninja -j 300 -C out/Default electron:electron_app - if "%GN_CONFIG%"=="testing" ( python C:\depot_tools\post_build_ninja_summary.py -C out\Default ) - gn gen out/ffmpeg "--args=import(\"//electron/build/args/ffmpeg.gn\") use_remoteexec=true %GN_EXTRA_ARGS%" - autoninja -C out/ffmpeg electron:electron_ffmpeg_zip diff --git a/appveyor.yml b/appveyor.yml index dea198f2589..67b1b898b60 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -123,8 +123,6 @@ for: if ($env:ELECTRON_RBE_JWT -eq '') { $env:RBE_fail_early_min_action_count = "0" $env:RBE_fail_early_min_fallback_ratio = "0" - $env:RBE_exec_strategy = "local" - $env:RBE_remote_update_cache= "false" } - cd ..\.. - ps: $env:CHROMIUM_BUILDTOOLS_PATH="$pwd\src\buildtools" @@ -153,7 +151,7 @@ for: - gn check out/Default //electron:electron_app - gn check out/Default //electron/shell/common:mojo - gn check out/Default //electron/shell/common:plugin - - if DEFINED ELECTRON_RBE_JWT (autoninja -j 300 -C out/Default electron:electron_app) else (autoninja -C out/Default electron:electron_app) + - autoninja -j 300 -C out/Default electron:electron_app - if "%GN_CONFIG%"=="testing" ( python C:\depot_tools\post_build_ninja_summary.py -C out\Default ) - gn gen out/ffmpeg "--args=import(\"//electron/build/args/ffmpeg.gn\") use_remoteexec=true %GN_EXTRA_ARGS%" - autoninja -C out/ffmpeg electron:electron_ffmpeg_zip