Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revise Actions workflows - fewer macos jobs, use Bundler cache, windows-2022, yjit job #2766

Merged
merged 1 commit into from Dec 13, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
51 changes: 31 additions & 20 deletions .github/workflows/mri.yml
Expand Up @@ -5,7 +5,7 @@ on: [push, pull_request, workflow_dispatch]
jobs:
build:
name: >-
${{ matrix.os }} ${{ matrix.ruby }}${{ matrix.no-ssl }}
${{ matrix.os }} ${{ matrix.ruby }}${{ matrix.no-ssl }}${{ matrix.yjit }}
env:
CI: true
TESTOPTS: -v
Expand All @@ -17,41 +17,47 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ ubuntu-20.04, ubuntu-18.04, macos-10.15, macos-11, windows-2019 ]
os: [ ubuntu-20.04, ubuntu-18.04, macos-10.15, macos-11, windows-2022 ]
ruby: [ 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, '3.0', head ]
no-ssl: ['']
yjit: ['']
include:
- { os: windows-2019 , ruby: mingw }
- { os: ubuntu-20.04 , ruby: 2.7 , no-ssl: ' no SSL' }
- { os: windows-2019 , ruby: 2.7 , no-ssl: ' no SSL' }
- { os: windows-2022 , ruby: ucrt }
- { os: windows-2022 , ruby: 2.7 , no-ssl: ' no SSL' }
- { os: ubuntu-20.04 , ruby: head , yjit: ' yjit' }
- { os: ubuntu-20.04 , ruby: 2.7 , no-ssl: ' no SSL' }

exclude:
- { os: ubuntu-20.04 , ruby: 2.2 }
- { os: ubuntu-20.04 , ruby: 2.3 }
- { os: ubuntu-20.04 , ruby: 2.4 }
- { os: ubuntu-20.04 , ruby: 2.6 }
- { os: windows-2019 , ruby: head }
- { os: windows-2022 , ruby: head }
- { os: macos-10.15 , ruby: 2.6 }
- { os: macos-10.15 , ruby: 2.7 }
- { os: macos-10.15 , ruby: '3.0' }
- { os: macos-11 , ruby: 2.2 }
- { os: macos-11 , ruby: 2.3 }

steps:
- name: repo checkout
uses: actions/checkout@v2

- name: load ruby, ragel
uses: MSP-Greg/setup-ruby-pkgs@v1
- name: load ruby
uses: MSP-Greg/setup-ruby-pkgs@win-ucrt-2
with:
ruby-version: ${{ matrix.ruby }}
apt-get: ragel
brew: ragel
mingw: _upgrade_ openssl ragel
mingw: openssl ragel
bundler-cache: true
setup-ruby-ref: MSP-Greg/ruby-setup-ruby/win-ucrt-1
timeout-minutes: 10

- name: bundle install
# Windows error thrown, doesn't affect CI
- name: update rubygems for Ruby 2.2
if: matrix.ruby < '2.3'
run: gem update --system 2.7.11 --no-document
continue-on-error: true
timeout-minutes: 5
shell: pwsh
run: |
# update RubyGems in Ruby 2.2, bundle install
if ('${{ matrix.ruby }}' -lt '2.3') {
gem update --system 2.7.11 --no-document
}
bundle install --jobs 4 --retry 3

- name: Compile Puma without SSL support
if: matrix.no-ssl == ' no SSL'
Expand All @@ -67,9 +73,14 @@ jobs:

- name: rubocop
# 2021-05-20 - RuboCop won't run with Psych 4.0 - remove when fixed
if: (endsWith(matrix.ruby, 'head') == false) && (endsWith(matrix.ruby, 'mingw') == false)
if: (endsWith(matrix.ruby, 'head') == false) && (endsWith(matrix.ruby, 'ucrt') == false)
run: bundle exec rake rubocop

- name: Use yjit
if: matrix.yjit == ' yjit'
shell: bash
run: echo 'RUBYOPT=--yjit' >> $GITHUB_ENV

- name: test
timeout-minutes: 10
run: bundle exec rake test:all
18 changes: 8 additions & 10 deletions .github/workflows/non_mri.yml
Expand Up @@ -32,23 +32,21 @@ jobs:
- name: repo checkout
uses: actions/checkout@v2

- name: set JAVA_HOME
if: startsWith(matrix.os, 'macos')
shell: bash
run: |
echo JAVA_HOME=$JAVA_HOME_11_X64 >> $GITHUB_ENV

- name: load ruby, ragel
uses: MSP-Greg/setup-ruby-pkgs@v1
with:
ruby-version: ${{ matrix.ruby }}
apt-get: ragel
brew: ragel
mingw: _upgrade_ openssl ragel

- name: set JAVA_HOME
if: startsWith(matrix.os, 'macos')
shell: bash
run: |
echo JAVA_HOME=$JAVA_HOME_11_X64 >> $GITHUB_ENV

- name: bundle install
timeout-minutes: 5
run: bundle install --jobs 4 --retry 3
bundler-cache: true
timeout-minutes: 10

- name: Compile Puma without SSL support
if: matrix.no-ssl == ' no SSL'
Expand Down