Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,30 +79,30 @@ jobs:
matrix:
include:
- platform: linux
runner: depot-ubuntu-24.04-4
runner: depot-ubuntu-24.04-8
target: x86_64-unknown-linux-musl
binary_ext: ""
arch: x86_64
# TODO: Add back when working
# - platform: linux
# runner: depot-ubuntu-24.04-arm-4
# runner: depot-ubuntu-24.04-arm-8
# target: aarch64-unknown-linux-musl
# binary_ext: ""
# arch: aarch64
- platform: windows
runner: depot-ubuntu-24.04-4
runner: depot-ubuntu-24.04-8
target: x86_64-pc-windows-gnu
binary_ext: ".exe"
arch: x86_64
- platform: macos
# Use Linux instead of macOS builders since macOS does not support Docker
runner: depot-ubuntu-24.04-4
runner: depot-ubuntu-24.04-8
target: x86_64-apple-darwin
binary_ext: ""
arch: x86_64
- platform: macos
# Use Linux instead of macOS builders since macOS does not support Docker
runner: depot-ubuntu-24.04-4
runner: depot-ubuntu-24.04-8
target: aarch64-apple-darwin
binary_ext: ""
arch: aarch64
Expand Down Expand Up @@ -162,10 +162,10 @@ jobs:
matrix:
include:
- platform: linux/arm64
runner: depot-ubuntu-24.04-arm-4
runner: depot-ubuntu-24.04-arm-8
arch_suffix: -arm64
- platform: linux/x86_64
runner: depot-ubuntu-24.04-4
runner: depot-ubuntu-24.04-8
arch_suffix: -amd64
runs-on: ${{ matrix.runner }}
steps:
Expand All @@ -188,7 +188,7 @@ jobs:
github_token: ${{ secrets.GITHUB_TOKEN}}

- name: Build & Push (rivetkit/engine:full)
uses: docker/build-push-action@v4
uses: depot/build-push-action@v1
with:
context: .
push: true
Expand All @@ -205,7 +205,7 @@ jobs:
# netrc=${{ runner.temp }}/netrc

- name: Build & Push (rivetkit/engine:slim)
uses: docker/build-push-action@v4
uses: depot/build-push-action@v1
with:
context: .
push: true
Expand Down
41 changes: 26 additions & 15 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ defaults:
# Enable fail-fast behavior
shell: bash -e {0}
env:
# Disable incremental compilation for faster from-scratch builds
CARGO_INCREMENTAL: 0
RUSTFLAGS: "--cfg tokio_unstable"
CARGO_TERM_COLOR: always
jobs:
Expand All @@ -34,8 +32,8 @@ jobs:
- '**/*.rs'
- '**/Cargo.toml'
- '**/Cargo.lock'
- '.github/workflows/rust-ci.yml'
- '.github/workflows/rust.yml'

fmt:
name: Rustfmt
runs-on: ubuntu-latest
Expand All @@ -49,28 +47,31 @@ jobs:
components: rustfmt
- name: Check formatting
run: cargo fmt --all -- --check

# clippy:
# name: Clippy
# runs-on: depot-ubuntu-24.04
# runs-on: depot-ubuntu-24.04-8
# needs: changes
# if: needs.changes.outputs.rust == 'true'
# steps:
# - uses: actions/checkout@v4
#
#
# - uses: actions-rust-lang/setup-rust-toolchain@v1
# with:
# toolchain: stable
# components: clippy
#
#
# - uses: Swatinem/rust-cache@v2
#
# with:
# shared-key: "rust-ci"
# cache-on-failure: true
#
# - name: Run clippy
# run: cargo clippy --all-targets --all-features -- -W warnings

check:
name: Check
runs-on: depot-ubuntu-24.04
runs-on: depot-ubuntu-24.04-8
needs: changes
if: needs.changes.outputs.rust == 'true'
steps:
Expand All @@ -79,15 +80,19 @@ jobs:
with:
toolchain: stable
- uses: Swatinem/rust-cache@v2
with:
shared-key: "rust-ci"
cache-on-failure: true

- name: Check
run: cargo check --all-targets --all-features
env:
# Deny warnings
RUSTFLAGS: --cfg tokio_unstable -D warnings

# test:
# name: Test
# runs-on: depot-ubuntu-24.04
# runs-on: depot-ubuntu-24.04-8
# needs: changes
# if: needs.changes.outputs.rust == 'true'
# steps:
Expand All @@ -98,6 +103,12 @@ jobs:
# toolchain: stable
#
# - uses: Swatinem/rust-cache@v2
# with:
# # Share cache across all Rust jobs
# shared-key: "rust-ci"
# # Save cache even if the build fails
# cache-on-failure: true
# # Only save cache on main branch to avoid cache pollution from PRs
#
# - name: Run tests
# run: cargo test --verbose
Expand Down Expand Up @@ -128,11 +139,11 @@ jobs:
echo "No Rust changes detected, skipping checks"
exit 0
fi

# If rust code changed, verify all jobs passed
if [ "${{ needs.fmt.result }}" == "failure" ] || [ "${{ needs.check.result }}" == "failure" ]; then
echo "One or more required jobs failed"
exit 1
fi

echo "All Rust checks passed"
Loading
Loading