From b32f2fe59b394fc0359907cf93d7f6e0e3cb4504 Mon Sep 17 00:00:00 2001 From: Sergey Kuznetsov Date: Thu, 16 Jul 2026 16:28:04 +0100 Subject: [PATCH] ci: Add Rust to CI (#7808) Co-authored-by: Ayaz Salikhov --- .cspell.config.yaml | 3 +++ .github/scripts/strategy-matrix/linux.json | 2 +- .github/workflows/publish-docs.yml | 4 ++-- .github/workflows/reusable-build-test-config.yml | 2 +- .github/workflows/reusable-clang-tidy.yml | 4 ++-- .github/workflows/reusable-upload-recipe.yml | 2 +- .github/workflows/upload-conan-deps.yml | 2 +- rust-toolchain.toml | 8 ++++++++ 8 files changed, 19 insertions(+), 8 deletions(-) create mode 100644 rust-toolchain.toml diff --git a/.cspell.config.yaml b/.cspell.config.yaml index 13da132b90..e220cd0249 100644 --- a/.cspell.config.yaml +++ b/.cspell.config.yaml @@ -262,6 +262,8 @@ words: - Rohrs - roundings - rustc + - rustfmt + - rustup - sahyadri - Satoshi - scons @@ -305,6 +307,7 @@ words: - takerpays - ters - TMEndpointv2 + - toolchain - tparam - trixie - tx diff --git a/.github/scripts/strategy-matrix/linux.json b/.github/scripts/strategy-matrix/linux.json index 03ac1c6334..7edbf96ef6 100644 --- a/.github/scripts/strategy-matrix/linux.json +++ b/.github/scripts/strategy-matrix/linux.json @@ -1,5 +1,5 @@ { - "image_tag": "sha-e29b523", + "image_tag": "sha-2e25435", "configs": { "ubuntu": [ { diff --git a/.github/workflows/publish-docs.yml b/.github/workflows/publish-docs.yml index 1ac8d61655..90182e7cbb 100644 --- a/.github/workflows/publish-docs.yml +++ b/.github/workflows/publish-docs.yml @@ -41,13 +41,13 @@ env: jobs: build: runs-on: ubuntu-latest - container: ghcr.io/xrplf/xrpld/nix-ubuntu:sha-e29b523 + container: ghcr.io/xrplf/xrpld/nix-ubuntu:sha-2e25435 steps: - name: Checkout repository uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 - name: Prepare runner - uses: XRPLF/actions/prepare-runner@64ec3cf3b152b4444638f470bbd6df7a7a30c81c + uses: XRPLF/actions/prepare-runner@ad188deb3dae79dc39816e16ddfdad1e06c6fab2 with: enable_ccache: false diff --git a/.github/workflows/reusable-build-test-config.yml b/.github/workflows/reusable-build-test-config.yml index b2327f67ea..975b788c0d 100644 --- a/.github/workflows/reusable-build-test-config.yml +++ b/.github/workflows/reusable-build-test-config.yml @@ -113,7 +113,7 @@ jobs: uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 - name: Prepare runner - uses: XRPLF/actions/prepare-runner@64ec3cf3b152b4444638f470bbd6df7a7a30c81c + uses: XRPLF/actions/prepare-runner@ad188deb3dae79dc39816e16ddfdad1e06c6fab2 with: enable_ccache: ${{ inputs.ccache_enabled }} diff --git a/.github/workflows/reusable-clang-tidy.yml b/.github/workflows/reusable-clang-tidy.yml index a6bbe669ce..4a10e4b0f7 100644 --- a/.github/workflows/reusable-clang-tidy.yml +++ b/.github/workflows/reusable-clang-tidy.yml @@ -34,7 +34,7 @@ jobs: needs: [determine-files] if: ${{ needs.determine-files.outputs.cpp_changed_files != '' || needs.determine-files.outputs.need_full_run == 'true' }} runs-on: ["self-hosted", "Linux", "X64", "heavy"] - container: "ghcr.io/xrplf/xrpld/nix-debian:sha-e29b523" + container: "ghcr.io/xrplf/xrpld/nix-debian:sha-2e25435" permissions: contents: read issues: write @@ -43,7 +43,7 @@ jobs: uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 - name: Prepare runner - uses: XRPLF/actions/prepare-runner@64ec3cf3b152b4444638f470bbd6df7a7a30c81c + uses: XRPLF/actions/prepare-runner@ad188deb3dae79dc39816e16ddfdad1e06c6fab2 with: enable_ccache: false diff --git a/.github/workflows/reusable-upload-recipe.yml b/.github/workflows/reusable-upload-recipe.yml index feeee0a621..07077163ed 100644 --- a/.github/workflows/reusable-upload-recipe.yml +++ b/.github/workflows/reusable-upload-recipe.yml @@ -40,7 +40,7 @@ defaults: jobs: upload: runs-on: ubuntu-latest - container: ghcr.io/xrplf/xrpld/nix-ubuntu:sha-e29b523 + container: ghcr.io/xrplf/xrpld/nix-ubuntu:sha-2e25435 env: REMOTE_NAME: ${{ inputs.remote_name }} CONAN_LOGIN_USERNAME_XRPLF: ${{ secrets.remote_username }} diff --git a/.github/workflows/upload-conan-deps.yml b/.github/workflows/upload-conan-deps.yml index 22ad36d98f..abc0867b15 100644 --- a/.github/workflows/upload-conan-deps.yml +++ b/.github/workflows/upload-conan-deps.yml @@ -68,7 +68,7 @@ jobs: uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 - name: Prepare runner - uses: XRPLF/actions/prepare-runner@64ec3cf3b152b4444638f470bbd6df7a7a30c81c + uses: XRPLF/actions/prepare-runner@ad188deb3dae79dc39816e16ddfdad1e06c6fab2 with: enable_ccache: false diff --git a/rust-toolchain.toml b/rust-toolchain.toml new file mode 100644 index 0000000000..dbc9e74c5d --- /dev/null +++ b/rust-toolchain.toml @@ -0,0 +1,8 @@ +# Rust toolchain pin for rustup-based CI runners and local development. +# rustup reads this file and installs the pinned toolchain (see the +# prepare-runner action in XRPLF/actions, which runs `rustup toolchain install`). +# NOTE: the Nix CI image and development shell ignore this file; its rustc comes from flake.lock. +[toolchain] +channel = "1.95" +components = ["rustfmt", "clippy"] +profile = "minimal"