Skip to content

Commit

Permalink
Actions: two workflows, 'MRI' & 'non_MRI', separate README badges (#2395
Browse files Browse the repository at this point in the history
)
  • Loading branch information
MSP-Greg committed Oct 1, 2020
1 parent 0d354a4 commit bb61c7b
Show file tree
Hide file tree
Showing 4 changed files with 85 additions and 75 deletions.
70 changes: 70 additions & 0 deletions .github/workflows/mri.yml
@@ -0,0 +1,70 @@
name: MRI

on: [push, pull_request]

jobs:
build:
name: >-
${{ matrix.os }} ${{ matrix.ruby }}${{ matrix.no-ssl }}
env:
CI: true
TESTOPTS: -v

runs-on: ${{ matrix.os }}
if: |
!( contains(github.event.pull_request.title, '[ci skip]')
|| contains(github.event.pull_request.title, '[skip ci]')
|| contains(github.event.head_commit.message, '[ci skip]')
|| contains(github.event.head_commit.message, '[skip ci]'))
strategy:
fail-fast: false
matrix:
os: [ ubuntu-20.04, ubuntu-18.04, macos-10.15, windows-2019 ]
ruby: [ 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, head ]
no-ssl: ['']
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' }
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 }

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

- 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: bundle install
shell: pwsh
run: |
# update RubyGems in Ruby 2.2, bundle install
if ('${{ matrix.ruby }}' -lt '2.3') {
gem update --system 2.7.10 --no-document
}
bundle install --jobs 4 --retry 3
- name: set SSL
if: matrix.no-ssl == ' no SSL'
run: echo '::set-env name=DISABLE_SSL::true'

- name: compile
run: bundle exec rake compile

- name: rubocop
if: startsWith(matrix.ruby, 'truffleruby') == false
run: bundle exec rake rubocop

- name: test
timeout-minutes: 10
run: bundle exec rake test:all
36 changes: 13 additions & 23 deletions .github/workflows/puma.yml → .github/workflows/non_mri.yml
@@ -1,11 +1,10 @@
name: CI

name: non_MRI
on: [push, pull_request]

jobs:
build:
name: >-
${{ matrix.os }} ${{ matrix.ruby }}
${{ matrix.os }} ${{ matrix.ruby }}${{ matrix.no-ssl }}
env:
CI: true
TESTOPTS: -v
Expand All @@ -19,24 +18,17 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ ubuntu-20.04, ubuntu-18.04, macos-10.15, windows-2019 ]
ruby: [ 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, head, jruby, jruby-head, truffleruby-head ]
os: [ ubuntu-20.04, ubuntu-18.04, macos-10.15 ]
ruby: [ jruby, jruby-head, truffleruby-head ]
no-ssl: ['']
include:
- { os: ubuntu-18.04 , ruby: jruby-head, allow-failure: true }
- { os: windows-2019 , ruby: mingw }
#- { os: ubuntu-18.04 , ruby: jruby-head, allow-failure: true }
- { os: ubuntu-20.04 , ruby: jruby, 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: ubuntu-20.04 , ruby: jruby }
- { os: ubuntu-20.04 , ruby: jruby-head }
- { os: ubuntu-20.04 , ruby: truffleruby-head }
- { os: macos-10.15 , ruby: jruby-head }
- { os: windows-2019 , ruby: head }
- { os: windows-2019 , ruby: jruby }
- { os: windows-2019 , ruby: jruby-head }
- { os: windows-2019 , ruby: truffleruby-head }

steps:
- name: repo checkout
Expand All @@ -50,14 +42,12 @@ jobs:
brew: ragel
mingw: _upgrade_ openssl ragel

- name: bundle install
shell: pwsh
run: |
# update RubyGems in Ruby 2.2, bundle install
if ('${{ matrix.ruby }}' -lt '2.3') {
gem update --system 2.7.10 --no-document
}
bundle install --jobs 4 --retry 3
- name: bundle install
run: bundle install --jobs 4 --retry 3

- name: set SSL
if: matrix.no-ssl == ' no SSL'
run: echo '::set-env name=DISABLE_SSL::true'

- name: compile
run: bundle exec rake compile
Expand Down
51 changes: 0 additions & 51 deletions .github/workflows/puma-no-ssl.yml

This file was deleted.

3 changes: 2 additions & 1 deletion README.md
Expand Up @@ -4,7 +4,8 @@

# Puma: A Ruby Web Server Built For Concurrency

[![Actions Build Status](https://github.com/puma/puma/workflows/CI/badge.svg?branch=master)](https://github.com/puma/puma/actions)
[![Actions MRI](https://github.com/puma/puma/workflows/MRI/badge.svg?branch=master)](https://github.com/puma/puma/actions?query=workflow%3AMRI)
[![Actions non MRI](https://github.com/puma/puma/workflows/non_MRI/badge.svg?branch=master)](https://github.com/puma/puma/actions?query=workflow%3Anon_MRI)
[![Code Climate](https://codeclimate.com/github/puma/puma.svg)](https://codeclimate.com/github/puma/puma)
[![SemVer](https://api.dependabot.com/badges/compatibility_score?dependency-name=puma&package-manager=bundler&version-scheme=semver)](https://dependabot.com/compatibility-score.html?dependency-name=puma&package-manager=bundler&version-scheme=semver)
[![StackOverflow](https://img.shields.io/badge/stackoverflow-Puma-blue.svg)]( https://stackoverflow.com/questions/tagged/puma )
Expand Down

0 comments on commit bb61c7b

Please sign in to comment.