Skip to content

Commit 6368ee0

Browse files
authored
CI: Add GitHub Actions ppc64le/s390x cases (#191)
This PR is working in progress to add GitHub Actions Ubuntu 24.04 ppc64le/s390x cases. This is one of the tasks that we add the cases in some ruby/* repositories. The task is tracked at IBM/actionspz#4 (comment). Maybe, this PR's change will be for only `.github/workflows/ci.yml`, while you see other changes in other files temporarily to work on this PR easily for now. I needed to sent a PR to this repository to test the ppc64le/s390x CI pipelines, rather than to test on my fork repository because GitHub Actions Ubuntu 24.04 ppc64le/s390x cases don't work in fork repositories unlike GitHub Actions x86_64/arm64 pipelines. I add the new job "host-ibm", because there are ppc64le/s390x specific logic, `if: github.repository == 'ruby/fiddle'` and "Set up Ruby" logic installing Ruby apt package. The `ruby/setup-ruby` doesn't support the ppc64le/s390x cases as far as I know. As a reference, we have applied the following code to a few ruby/* repositories. * ruby/ruby: https://github.com/ruby/ruby/blob/master/.github/workflows/ubuntu-ibm.yml * ruby/prism: https://github.com/ruby/prism/blob/07de61d4702d12c985d0a708445cf6f3e1935989/.github/workflows/main.yml#L81-L100 * ruby/psych: https://github.com/ruby/psych/blob/1d9c52706b2572a37248a1bdf3f83cc6ef07fd83/.github/workflows/test.yml#L64-L86 * ruby/zlib: https://github.com/ruby/zlib/blob/b2ec227080d79fb16e7df2659c8fe943b5a9452d/.github/workflows/test.yml#L45-L64
1 parent 4e54478 commit 6368ee0

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

.github/workflows/ci.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,40 @@ jobs:
7777
cd tmp
7878
ruby test/run.rb
7979
80+
host-ibm:
81+
if: github.repository == 'ruby/fiddle'
82+
name: ${{ matrix.os }}
83+
runs-on: ${{ matrix.os }}
84+
strategy:
85+
fail-fast: false
86+
matrix:
87+
os:
88+
- ubuntu-24.04-ppc64le
89+
- ubuntu-24.04-s390x
90+
91+
steps:
92+
- uses: actions/checkout@v5
93+
94+
- name: Set up Ruby
95+
run: |
96+
sudo apt-get update
97+
sudo apt-get install ruby-full bundler libffi-dev
98+
99+
- run: sudo bundle install --jobs $(nproc)
100+
101+
- run: rake compile
102+
103+
- run: ruby -Ilib test/run.rb
104+
105+
- run: sudo rake install
106+
107+
- name: Run test against installed gem
108+
run: |
109+
ruby -run -e mkdir -- -p tmp/
110+
ruby -run -e cp -- -pr test/ tmp/
111+
cd tmp
112+
ruby test/run.rb
113+
80114
docker:
81115
name: >-
82116
${{ matrix.service }}

0 commit comments

Comments
 (0)