From e95781bde1fe9b69b00718ec9eb6de6f9070fabd Mon Sep 17 00:00:00 2001 From: Pratik Mankawde <3397372+pratikmankawde@users.noreply.github.com> Date: Thu, 12 Mar 2026 20:10:18 +0000 Subject: [PATCH] Fix prepare-runner /root permission error on ubuntu-latest The XRPLF/actions/prepare-runner action hardcodes /root/.ccache and /root/.conan2 for Linux, assuming container execution as root. This workflow runs natively on ubuntu-latest as the runner user. Replace prepare-runner with inline apt-get install of ccache + ninja, and use CMake compiler launchers for ccache instead. Keep all other main CI patterns: pinned actions, get-nproc, env-based secrets, CCACHE_SLOPPINESS, print-env step. Co-Authored-By: Claude Opus 4.6 --- .github/workflows/telemetry-validation.yml | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/.github/workflows/telemetry-validation.yml b/.github/workflows/telemetry-validation.yml index dd7c7f45f5..3d3726bd45 100644 --- a/.github/workflows/telemetry-validation.yml +++ b/.github/workflows/telemetry-validation.yml @@ -15,6 +15,11 @@ # - setup-conan action → build-deps action → cmake configure → cmake build # This ensures dependency resolution, toolchain generation, and compiler # flags are identical to what the PR workflow uses. +# +# NOTE: Unlike the main CI, this workflow runs natively on ubuntu-latest +# (not in a container), so we cannot use XRPLF/actions/prepare-runner +# which assumes /root paths. Instead we replicate the relevant setup +# steps inline. name: Telemetry Validation @@ -60,6 +65,7 @@ concurrency: env: BUILD_DIR: build + # ccache configuration — mirrors reusable-build-test-config.yml CCACHE_NAMESPACE: telemetry-validation CCACHE_REMOTE_ONLY: true CCACHE_REMOTE_STORAGE: http://cache.dev.ripplex.io:8080|layout=bazel @@ -75,10 +81,13 @@ jobs: - name: Checkout repository uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - - name: Prepare runner - uses: XRPLF/actions/prepare-runner@2cbf481018d930656e9276fcc20dc0e3a0be5b6d - with: - enable_ccache: true + - name: Install system dependencies + run: | + sudo apt-get update + sudo apt-get install -y curl jq bc ninja-build ccache + + - name: Install Python dependencies + run: pip3 install -r docker/telemetry/workload/requirements.txt - name: Print build environment uses: ./.github/actions/print-env @@ -89,9 +98,6 @@ jobs: with: subtract: 2 - - name: Install Python dependencies - run: pip3 install -r docker/telemetry/workload/requirements.txt - # ── Build steps (mirrors main CI: setup-conan → build-deps → cmake) ── - name: Setup Conan @@ -117,6 +123,8 @@ jobs: -G Ninja \ -DCMAKE_TOOLCHAIN_FILE:FILEPATH=build/generators/conan_toolchain.cmake \ -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_C_COMPILER_LAUNCHER=ccache \ + -DCMAKE_CXX_COMPILER_LAUNCHER=ccache \ .. - name: Build xrpld