Ruby
Ruby CI on GitHub Actions
bundle install compiles native gems from source on every run.
140s → 6s
bundle install
18m → 4m
RSpec
bundle install compiles native gems from source on every run.
Why it happens
Gems like nokogiri, pg and grpc build C extensions, which costs minutes unless the built gems are cached.
What to change
- Cache vendor/bundle keyed on Gemfile.lock so native extensions are built once
- Set bundle config deployment true for reproducible, lockfile-exact installs
- Run RSpec in parallel with parallel_tests across all available cores
- Use a snapshot runner if install still dominates — it removes the step entirely
Ruby on runnerhut
yaml
jobs: test: runs-on: runnerhut-8vcpu-ubuntu-2404 steps: - uses: actions/checkout@v4 - uses: ruby/setup-ruby@v1 with: { ruby-version: '3.3', bundler-cache: true } - run: bundle exec parallel_rspec spec/The only runnerhut-specific line is `runs-on: runnerhut-8vcpu-ubuntu-2404`. Everything else is standard GitHub Actions — the same actions, the same secrets and the same permissions model you use today.
Your next build could be twice as fast, at half the price
Start free. Migrating away is the same one line, and we publish that diff too.