From f8932deb37dfe1268c1a96295953b4b619f2f7bb Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 11:14:26 +0000 Subject: [PATCH 01/14] u Signed-off-by: Joe Isaacs --- .github/workflows/ci.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8ad48e0efd5..a9f845590fa 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -191,7 +191,7 @@ jobs: - runs-on=${{ github.run_id }} - family=m7i+m7i-flex+m7a - cpu=8 - - image=ubuntu24-full-x64 + - image=vortex-ci-amd64 - extras=s3-cache - tag=${{ matrix.config.name }} env: @@ -273,10 +273,6 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: ./.github/actions/setup-rust - with: - toolchain: nightly - repo-token: ${{ secrets.GITHUB_TOKEN }} - name: Rust Lint - Format run: cargo +nightly fmt --all --check - name: Rustc check From e746d127cee7314217d5f769591903ace795b0d5 Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 11:29:30 +0000 Subject: [PATCH 02/14] u Signed-off-by: Joe Isaacs --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3f5c521c17e..44b2fc7342a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -190,7 +190,7 @@ jobs: - runs-on=${{ github.run_id }} - family=m7i+m7i-flex+m7a - cpu=8 - - image=ubuntu24-full-x64 + - image=vortex-ci-amd64 - extras=s3-cache - tag=${{ matrix.config.name }} env: From 91a4d464d99fd17305863af65636829581e63a07 Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 11:36:59 +0000 Subject: [PATCH 03/14] u Signed-off-by: Joe Isaacs --- .github/runs-on.yml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/runs-on.yml b/.github/runs-on.yml index 7970bf75e17..bad0ddf2b9f 100644 --- a/.github/runs-on.yml +++ b/.github/runs-on.yml @@ -1,11 +1,17 @@ +# Custom AMIs for Vortex CI runners +# These AMIs are automatically rebuilt every 15 days by the ami-prebuild.yml workflow +# to keep the GitHub Actions runner agent up to date (required to be <30 days old). +# +# AMI naming pattern: vortex-ci-{arch}-{timestamp} +# Built with: .github/actions/build-ami and .github/packer/vortex-ci.pkr.hcl images: vortex-ci-amd64: platform: "linux" arch: "x64" - name: "vortex-ci-*" + name: "vortex-ci-x64-*" owner: "375504701696" vortex-ci-arm64: platform: "linux" arch: "arm64" - name: "vortex-ci-*" + name: "vortex-ci-arm64-*" owner: "375504701696" From b7d8c99ac442552276eee1b5c537862cd059bf26 Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 11:48:49 +0000 Subject: [PATCH 04/14] u Signed-off-by: Joe Isaacs --- .github/workflows/ci.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 44b2fc7342a..0851229a137 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -188,9 +188,7 @@ jobs: timeout-minutes: 120 runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=8 - - image=vortex-ci-amd64 + - runner=rust-amd64-medium - extras=s3-cache - tag=${{ matrix.config.name }} env: From 962dda2be1424f0c4bb8d56ca363dfc96e0f9221 Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 11:51:40 +0000 Subject: [PATCH 05/14] u Signed-off-by: Joe Isaacs --- .github/runs-on.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/runs-on.yml b/.github/runs-on.yml index bad0ddf2b9f..4b720e77059 100644 --- a/.github/runs-on.yml +++ b/.github/runs-on.yml @@ -4,6 +4,12 @@ # # AMI naming pattern: vortex-ci-{arch}-{timestamp} # Built with: .github/actions/build-ami and .github/packer/vortex-ci.pkr.hcl +runners: + rust-amd64-medium: + image: vortex-ci-amd64 + cpu: 8 + family: [m7i, m7i-flex, m7a] + images: vortex-ci-amd64: platform: "linux" From 52ec02cc928612540536f2a41ecdbf6489165f56 Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 13:43:38 +0000 Subject: [PATCH 06/14] u Signed-off-by: Joe Isaacs --- .github/runs-on.yml | 4 ++++ .github/workflows/ci.yml | 44 ++++++++++------------------------------ 2 files changed, 15 insertions(+), 33 deletions(-) diff --git a/.github/runs-on.yml b/.github/runs-on.yml index 4b720e77059..c7c0fc2ac3b 100644 --- a/.github/runs-on.yml +++ b/.github/runs-on.yml @@ -9,6 +9,10 @@ runners: image: vortex-ci-amd64 cpu: 8 family: [m7i, m7i-flex, m7a] + rust-amd64-large: + image: vortex-ci-amd64 + cpu: 16 + family: [m7i, m7i-flex, m7a] images: vortex-ci-amd64: diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0851229a137..bf5114a70df 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -49,9 +49,7 @@ jobs: name: "Python (lint)" runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=16 - - image=ubuntu24-full-x64 + - runner=rust-amd64-large - extras=s3-cache - tag=python-lint timeout-minutes: 120 @@ -81,9 +79,7 @@ jobs: name: "Python (test)" runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=16 - - image=ubuntu24-full-x64 + - runner=rust-amd64-large - extras=s3-cache - tag=python-test timeout-minutes: 120 @@ -164,9 +160,7 @@ jobs: timeout-minutes: 120 runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=8 - - image=ubuntu24-full-x64 + - runner=rust-amd64-medium - extras=s3-cache - tag=rust-docs steps: @@ -243,9 +237,7 @@ jobs: timeout-minutes: 120 runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=8 - - image=ubuntu24-full-x64 + - runner=rust-amd64-medium - extras=s3-cache - tag=rust-min-deps steps: @@ -265,9 +257,7 @@ jobs: timeout-minutes: 120 runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=16 - - image=ubuntu24-full-x64 + - runner=rust-amd64-large - extras=s3-cache - tag=rust-lint steps: @@ -300,9 +290,7 @@ jobs: timeout-minutes: 120 runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=16 - - image=ubuntu24-full-x64 + - runner=rust-amd64-large - extras=s3-cache - tag=rust-lint-no-default steps: @@ -332,9 +320,7 @@ jobs: if: github.ref != 'refs/heads/develop' runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=16 - - image=ubuntu24-full-x64 + - runner=rust-amd64-large - extras=s3-cache - tag=rust-semver steps: @@ -376,9 +362,7 @@ jobs: - ffi runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=16 - - image=ubuntu24-full-x64 + - runner=rust-amd64-large - extras=s3-cache - tag=rust-coverage - tag=suite-${{ matrix.suite }} @@ -450,9 +434,7 @@ jobs: timeout-minutes: 120 runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=16 - - image=ubuntu24-full-x64 + - runner=rust-amd64-large - extras=s3-cache - tag=rust-test-sanitizer env: @@ -567,9 +549,7 @@ jobs: name: "Java" runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=16 - - image=ubuntu24-full-x64 + - runner=rust-amd64-large - extras=s3-cache - tag=java timeout-minutes: 120 @@ -651,9 +631,7 @@ jobs: timeout-minutes: 120 runs-on: - runs-on=${{ github.run_id }} - - family=m7i+m7i-flex+m7a - - cpu=8 - - image=ubuntu24-full-x64 + - runner=rust-amd64-medium - extras=s3-cache - tag=cxx-build steps: From da41bf4d0861820b2a7a9c26d41513c01fc4e6b6 Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 14:07:07 +0000 Subject: [PATCH 07/14] u Signed-off-by: Joe Isaacs --- .github/workflows/ci.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bf5114a70df..01e9bee2bf9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -213,10 +213,10 @@ jobs: sccache: s3 - uses: actions/checkout@v6 - id: setup-rust - uses: ./.github/actions/setup-rust - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - timestamp: "true" +# uses: ./.github/actions/setup-rust +# with: +# repo-token: ${{ secrets.GITHUB_TOKEN }} +# timestamp: "true" - name: Install wasm32 target if: ${{ matrix.config.target == 'wasm32-unknown-unknown' }} run: rustup target add wasm32-unknown-unknown From 8d43efc469bd63cc5fca68597ed8c359b189f498 Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 14:09:10 +0000 Subject: [PATCH 08/14] u Signed-off-by: Joe Isaacs --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 01e9bee2bf9..a3417e893f3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -212,7 +212,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - id: setup-rust +# - id: setup-rust # uses: ./.github/actions/setup-rust # with: # repo-token: ${{ secrets.GITHUB_TOKEN }} From 453fc4afe1c5ac39c6ba46c596009ba4490faf1f Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 15:22:47 +0000 Subject: [PATCH 09/14] u Signed-off-by: Joe Isaacs --- .github/workflows/ci.yml | 97 ++-------------------------------------- 1 file changed, 4 insertions(+), 93 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a3417e893f3..98fa9e6cb78 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -58,9 +58,6 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: ./.github/actions/setup-rust - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - name: Install uv uses: spiraldb/actions/.github/actions/setup-uv@0.18.5 with: @@ -90,9 +87,6 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: ./.github/actions/setup-rust - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - name: Install uv uses: spiraldb/actions/.github/actions/setup-uv@0.18.5 with: @@ -168,9 +162,6 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: ./.github/actions/setup-rust - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - name: Docs run: | RUSTDOCFLAGS="-D warnings" cargo doc --no-deps @@ -212,25 +203,12 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 -# - id: setup-rust -# uses: ./.github/actions/setup-rust -# with: -# repo-token: ${{ secrets.GITHUB_TOKEN }} -# timestamp: "true" - - name: Install wasm32 target - if: ${{ matrix.config.target == 'wasm32-unknown-unknown' }} - run: rustup target add wasm32-unknown-unknown - - name: Install cargo-hack - uses: taiki-e/install-action@cargo-hack - name: Rust Build (${{matrix.config.name}}) run: ${{matrix.config.env.rustflags}} cargo hack ${{matrix.config.command}} --locked ${{matrix.config.args}} --ignore-private - name: "Make sure no files changed after build" run: | git status --porcelain test -z "$(git status --porcelain)" - - name: Prune cache - if: ${{ github.ref_name == 'develop' && steps.setup-rust.outputs.deps-cache-hit != 'true' }} - run: cargo sweep --file check-min-deps: name: "Check build with minimal dependencies" @@ -245,11 +223,6 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: ./.github/actions/setup-rust - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - - uses: taiki-e/install-action@cargo-hack - - uses: taiki-e/install-action@cargo-minimal-versions - run: cargo minimal-versions check --direct --workspace --ignore-private rust-lint: @@ -265,12 +238,6 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - id: setup-rust - uses: ./.github/actions/setup-rust - with: - toolchain: nightly - repo-token: ${{ secrets.GITHUB_TOKEN }} - timestamp: "true" - name: Rust Lint - Format run: cargo +nightly fmt --all --check - name: Rustc check @@ -281,9 +248,6 @@ jobs: run: cargo clippy --locked --all-features --all-targets -- -D warnings - name: Rust Lint - Clippy Default Features run: cargo clippy --locked --all-targets -- -D warnings - - name: Prune cache - if: ${{ github.ref_name == 'develop' && steps.setup-rust.outputs.deps-cache-hit != 'true' }} - run: cargo sweep --file rust-lint-no-default: name: "Rust (lint, no default)" @@ -298,21 +262,11 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - id: setup-rust - uses: ./.github/actions/setup-rust - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - timestamp: "true" - - name: Install cargo-hack - uses: taiki-e/install-action@cargo-hack - name: Rust Lint - Clippy No Default Features shell: bash run: | # https://spiraldb.slack.com/archives/C07BV3GKAJ2/p1732736281946729 cargo hack clippy --no-default-features -- -D warnings - - name: Prune cache - if: ${{ github.ref_name == 'develop' && steps.setup-rust.outputs.deps-cache-hit != 'true' }} - run: cargo sweep --file rust-semver: name: "Rust (semver checks)" @@ -331,9 +285,6 @@ jobs: with: fetch-depth: 0 fetch-tags: true - - uses: ./.github/actions/setup-rust - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} # We have to set the correct Cargo.toml versions so semver checks uses the previous release. - name: Latest Tag @@ -342,9 +293,7 @@ jobs: LATEST_TAG=$(git describe --tags --abbrev=0) echo "tag=$LATEST_TAG" >> $GITHUB_OUTPUT - name: Cargo Set Version - run: | - cargo install cargo-edit - cargo set-version --workspace ${{ steps.latest-tag.outputs.tag }} + run: cargo set-version --workspace ${{ steps.latest-tag.outputs.tag }} - name: Check semver uses: obi1kenobi/cargo-semver-checks-action@v2 @@ -376,17 +325,6 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - id: setup-rust - uses: ./.github/actions/setup-rust - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - timestamp: "true" - - name: Install grcov - uses: taiki-e/install-action@grcov - - name: Install nextest - uses: taiki-e/install-action@v2 - with: - tool: nextest - name: Rust Tests if: ${{ matrix.suite == 'tests' }} env: @@ -404,8 +342,6 @@ jobs: run: | cargo build -p vortex-ffi cargo run -p vortex-ffi --example hello_vortex - - name: Install llvm-tools-preview - run: rustup component add llvm-tools-preview - name: Generate coverage report run: | grcov . --binary-path target/debug/ -s . -t lcov --llvm --ignore-not-existing \ @@ -425,9 +361,6 @@ jobs: disable_search: true flags: ${{ matrix.suite }} use_oidc: true - - name: Prune cache - if: ${{ github.ref_name == 'develop' && steps.setup-rust.outputs.deps-cache-hit != 'true' }} - run: cargo sweep --file rust-test: name: "Rust tests (sanitizer)" @@ -457,22 +390,6 @@ jobs: with: compiler: llvm cache-tools: true - - id: setup-rust - uses: ./.github/actions/setup-rust - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - toolchain: nightly - components: "rust-src, rustfmt, clippy, llvm-tools-preview" - cache-suffix: "sanitizer" - timestamp: "true" - - name: Install build dependencies - run: | - sudo apt-get update - sudo apt-get install -y ninja-build cmake - - name: Install nextest - uses: taiki-e/install-action@v2 - with: - tool: nextest - name: Rust Tests env: RUSTFLAGS: "-A warnings -Zsanitizer=address -Zsanitizer=leak --cfg disable_loom --cfg vortex_nightly -C debuginfo=2 -C opt-level=0 -C strip=none" @@ -487,9 +404,6 @@ jobs: --no-fail-fast \ --target x86_64-unknown-linux-gnu \ --verbose - - name: Prune cache - if: ${{ github.ref_name == 'develop' && steps.setup-rust.outputs.deps-cache-hit != 'true' }} - run: cargo sweep --file rust-test-other: name: "Rust tests (${{ matrix.os }})" @@ -562,9 +476,6 @@ jobs: with: distribution: "corretto" java-version: "17" - - uses: ./.github/actions/setup-rust - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - run: ./gradlew test --parallel working-directory: ./java @@ -635,10 +546,10 @@ jobs: - extras=s3-cache - tag=cxx-build steps: - - uses: actions/checkout@v6 - - uses: ./.github/actions/setup-rust + - uses: runs-on/action@v2 with: - repo-token: ${{ secrets.GITHUB_TOKEN }} + sccache: s3 + - uses: actions/checkout@v6 - name: Build and run C++ unit tests working-directory: vortex-cxx/ run: | From 9a778400e888bc7129137b412a83203a67fc985e Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 15:36:16 +0000 Subject: [PATCH 10/14] u Signed-off-by: Joe Isaacs --- .github/workflows/ci.yml | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 98fa9e6cb78..323bebcf49a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -58,6 +58,9 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 + - uses: Swatinem/rust-cache@v2 + with: + save-if: ${{ github.ref_name == 'develop' }} - name: Install uv uses: spiraldb/actions/.github/actions/setup-uv@0.18.5 with: @@ -87,6 +90,9 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 + - uses: Swatinem/rust-cache@v2 + with: + save-if: ${{ github.ref_name == 'develop' }} - name: Install uv uses: spiraldb/actions/.github/actions/setup-uv@0.18.5 with: @@ -162,6 +168,9 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 + - uses: Swatinem/rust-cache@v2 + with: + save-if: ${{ github.ref_name == 'develop' }} - name: Docs run: | RUSTDOCFLAGS="-D warnings" cargo doc --no-deps @@ -203,6 +212,9 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 + - uses: Swatinem/rust-cache@v2 + with: + save-if: ${{ github.ref_name == 'develop' }} - name: Rust Build (${{matrix.config.name}}) run: ${{matrix.config.env.rustflags}} cargo hack ${{matrix.config.command}} --locked ${{matrix.config.args}} --ignore-private - name: "Make sure no files changed after build" @@ -223,6 +235,9 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 + - uses: Swatinem/rust-cache@v2 + with: + save-if: ${{ github.ref_name == 'develop' }} - run: cargo minimal-versions check --direct --workspace --ignore-private rust-lint: @@ -238,6 +253,9 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 + - uses: Swatinem/rust-cache@v2 + with: + save-if: ${{ github.ref_name == 'develop' }} - name: Rust Lint - Format run: cargo +nightly fmt --all --check - name: Rustc check @@ -262,6 +280,9 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 + - uses: Swatinem/rust-cache@v2 + with: + save-if: ${{ github.ref_name == 'develop' }} - name: Rust Lint - Clippy No Default Features shell: bash run: | @@ -285,6 +306,9 @@ jobs: with: fetch-depth: 0 fetch-tags: true + - uses: Swatinem/rust-cache@v2 + with: + save-if: ${{ github.ref_name == 'develop' }} # We have to set the correct Cargo.toml versions so semver checks uses the previous release. - name: Latest Tag @@ -325,6 +349,9 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 + - uses: Swatinem/rust-cache@v2 + with: + save-if: ${{ github.ref_name == 'develop' }} - name: Rust Tests if: ${{ matrix.suite == 'tests' }} env: @@ -385,6 +412,9 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 + - uses: Swatinem/rust-cache@v2 + with: + save-if: ${{ github.ref_name == 'develop' }} - name: Install llvm uses: aminya/setup-cpp@v1 with: From 0da42378abd179d2bb2794120e6e15003e287943 Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 15:47:51 +0000 Subject: [PATCH 11/14] u Signed-off-by: Joe Isaacs --- .github/actions/setup-rust-2/action.yml | 37 ++++++++++++++++++++++ .github/workflows/ci.yml | 42 +++++++------------------ 2 files changed, 49 insertions(+), 30 deletions(-) create mode 100644 .github/actions/setup-rust-2/action.yml diff --git a/.github/actions/setup-rust-2/action.yml b/.github/actions/setup-rust-2/action.yml new file mode 100644 index 00000000000..6230d030117 --- /dev/null +++ b/.github/actions/setup-rust-2/action.yml @@ -0,0 +1,37 @@ +name: "Setup Rust (Custom AMI)" +description: "Lightweight Rust setup for custom AMI runners with pre-installed toolchain" + +inputs: + cache-suffix: + description: "optional suffix for cache key to isolate builds with different RUSTFLAGS (e.g. 'sanitizer')" + required: false + default: "" + targets: + description: "optional targets override (for cache key compatibility)" + required: false + timestamp: + description: "Timestamp cache with cargo sweep" + default: "false" + +runs: + using: "composite" + steps: + - name: Get Rust version for cache key + id: rust-version + shell: bash + run: | + # Get a short hash of the rustc version (matches dtolnay/rust-toolchain cachekey format) + RUSTC_VERSION=$(rustc --version) + CACHEKEY=$(echo "$RUSTC_VERSION" | sha256sum | cut -c1-20) + echo "cachekey=$CACHEKEY" >> $GITHUB_OUTPUT + + - name: Rust Dependency Cache + uses: Swatinem/rust-cache@v2 + with: + # save-if: ${{ github.ref_name == 'develop' }} + shared-key: "rust-cache-${{ runner.os }}-${{ runner.arch }}-${{ runner.environment }}-${{ steps.rust-version.outputs.cachekey }}-${{ inputs.targets }}${{ inputs.cache-suffix && format('-{0}', inputs.cache-suffix) || '' }}" + + - name: Timestamp Cache + shell: bash + if: ${{ inputs.timestamp == 'true' && github.ref_name == 'develop' }} + run: cargo sweep --stamp diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 323bebcf49a..0adf00e947d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -58,9 +58,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: Swatinem/rust-cache@v2 - with: - save-if: ${{ github.ref_name == 'develop' }} + - uses: ./.github/actions/setup-rust-2 - name: Install uv uses: spiraldb/actions/.github/actions/setup-uv@0.18.5 with: @@ -90,9 +88,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: Swatinem/rust-cache@v2 - with: - save-if: ${{ github.ref_name == 'develop' }} + - uses: ./.github/actions/setup-rust-2 - name: Install uv uses: spiraldb/actions/.github/actions/setup-uv@0.18.5 with: @@ -168,9 +164,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: Swatinem/rust-cache@v2 - with: - save-if: ${{ github.ref_name == 'develop' }} + - uses: ./.github/actions/setup-rust-2 - name: Docs run: | RUSTDOCFLAGS="-D warnings" cargo doc --no-deps @@ -212,9 +206,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: Swatinem/rust-cache@v2 - with: - save-if: ${{ github.ref_name == 'develop' }} + - uses: ./.github/actions/setup-rust-2 - name: Rust Build (${{matrix.config.name}}) run: ${{matrix.config.env.rustflags}} cargo hack ${{matrix.config.command}} --locked ${{matrix.config.args}} --ignore-private - name: "Make sure no files changed after build" @@ -235,9 +227,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: Swatinem/rust-cache@v2 - with: - save-if: ${{ github.ref_name == 'develop' }} + - uses: ./.github/actions/setup-rust-2 - run: cargo minimal-versions check --direct --workspace --ignore-private rust-lint: @@ -253,9 +243,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: Swatinem/rust-cache@v2 - with: - save-if: ${{ github.ref_name == 'develop' }} + - uses: ./.github/actions/setup-rust-2 - name: Rust Lint - Format run: cargo +nightly fmt --all --check - name: Rustc check @@ -280,9 +268,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: Swatinem/rust-cache@v2 - with: - save-if: ${{ github.ref_name == 'develop' }} + - uses: ./.github/actions/setup-rust-2 - name: Rust Lint - Clippy No Default Features shell: bash run: | @@ -306,9 +292,7 @@ jobs: with: fetch-depth: 0 fetch-tags: true - - uses: Swatinem/rust-cache@v2 - with: - save-if: ${{ github.ref_name == 'develop' }} + - uses: ./.github/actions/setup-rust-2 # We have to set the correct Cargo.toml versions so semver checks uses the previous release. - name: Latest Tag @@ -349,9 +333,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: Swatinem/rust-cache@v2 - with: - save-if: ${{ github.ref_name == 'develop' }} + - uses: ./.github/actions/setup-rust-2 - name: Rust Tests if: ${{ matrix.suite == 'tests' }} env: @@ -412,9 +394,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 - - uses: Swatinem/rust-cache@v2 - with: - save-if: ${{ github.ref_name == 'develop' }} + - uses: ./.github/actions/setup-rust-2 - name: Install llvm uses: aminya/setup-cpp@v1 with: @@ -502,6 +482,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 + - uses: ./.github/actions/setup-rust-2 - uses: actions/setup-java@v5 with: distribution: "corretto" @@ -580,6 +561,7 @@ jobs: with: sccache: s3 - uses: actions/checkout@v6 + - uses: ./.github/actions/setup-rust-2 - name: Build and run C++ unit tests working-directory: vortex-cxx/ run: | From bf26105f13d654fb8b53359eff80cf4a31c3d50b Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 15:48:08 +0000 Subject: [PATCH 12/14] u Signed-off-by: Joe Isaacs --- .github/runs-on.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/runs-on.yml b/.github/runs-on.yml index c7c0fc2ac3b..63cb2753423 100644 --- a/.github/runs-on.yml +++ b/.github/runs-on.yml @@ -1,6 +1,7 @@ # Custom AMIs for Vortex CI runners -# These AMIs are automatically rebuilt every 15 days by the ami-prebuild.yml workflow +# These AMIs are automatically rebuilt every 25 days by the ami-prebuild.yml workflow # to keep the GitHub Actions runner agent up to date (required to be <30 days old). +# AMIs are deprecated after 25 days via Packer's deprecate_at setting. # # AMI naming pattern: vortex-ci-{arch}-{timestamp} # Built with: .github/actions/build-ami and .github/packer/vortex-ci.pkr.hcl From 6b7731d3b82106876b6bc3442a75b8ea856491cf Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 17:21:07 +0000 Subject: [PATCH 13/14] u Signed-off-by: Joe Isaacs --- .github/actions/setup-rust-2/action.yml | 5 ++++- .github/workflows/ci.yml | 5 ----- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/.github/actions/setup-rust-2/action.yml b/.github/actions/setup-rust-2/action.yml index 6230d030117..bbb5479f5bd 100644 --- a/.github/actions/setup-rust-2/action.yml +++ b/.github/actions/setup-rust-2/action.yml @@ -28,9 +28,12 @@ runs: - name: Rust Dependency Cache uses: Swatinem/rust-cache@v2 with: - # save-if: ${{ github.ref_name == 'develop' }} +# save-if: ${{ github.ref_name == 'develop' }} shared-key: "rust-cache-${{ runner.os }}-${{ runner.arch }}-${{ runner.environment }}-${{ steps.rust-version.outputs.cachekey }}-${{ inputs.targets }}${{ inputs.cache-suffix && format('-{0}', inputs.cache-suffix) || '' }}" + - name: Rust Compile Cache + uses: mozilla-actions/sccache-action@v0.0.9 + - name: Timestamp Cache shell: bash if: ${{ inputs.timestamp == 'true' && github.ref_name == 'develop' }} diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0adf00e947d..fce755ccd88 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -395,11 +395,6 @@ jobs: sccache: s3 - uses: actions/checkout@v6 - uses: ./.github/actions/setup-rust-2 - - name: Install llvm - uses: aminya/setup-cpp@v1 - with: - compiler: llvm - cache-tools: true - name: Rust Tests env: RUSTFLAGS: "-A warnings -Zsanitizer=address -Zsanitizer=leak --cfg disable_loom --cfg vortex_nightly -C debuginfo=2 -C opt-level=0 -C strip=none" From 3d98bb8c1b06600a3e1081b984ff482ac137763f Mon Sep 17 00:00:00 2001 From: Joe Isaacs Date: Wed, 7 Jan 2026 17:52:17 +0000 Subject: [PATCH 14/14] u Signed-off-by: Joe Isaacs --- .github/actions/setup-rust-2/action.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/actions/setup-rust-2/action.yml b/.github/actions/setup-rust-2/action.yml index bbb5479f5bd..2bc11137dc9 100644 --- a/.github/actions/setup-rust-2/action.yml +++ b/.github/actions/setup-rust-2/action.yml @@ -31,8 +31,8 @@ runs: # save-if: ${{ github.ref_name == 'develop' }} shared-key: "rust-cache-${{ runner.os }}-${{ runner.arch }}-${{ runner.environment }}-${{ steps.rust-version.outputs.cachekey }}-${{ inputs.targets }}${{ inputs.cache-suffix && format('-{0}', inputs.cache-suffix) || '' }}" - - name: Rust Compile Cache - uses: mozilla-actions/sccache-action@v0.0.9 + # Note: sccache is configured by runs-on/action with sccache: s3 in the workflow + # Do NOT add mozilla-actions/sccache-action here as it would override S3 config with GH cache - name: Timestamp Cache shell: bash