Skip to content

Commit 3adee3b

Browse files
committed
Support GitHub's Linux arm64 preview hosts
The action already worked without issue on Linux arm64, just the tests needed to be updated to test the new architecture correctly. Also included a handy `plugins.md` reference file, which is intended as an internal reference only. Squashed commit of the following: commit 9c09bfc Author: Paul Colby <[email protected]> Date: Fri Jan 17 13:11:51 2025 +1100 Trim leading and trailing whitespace too commit 33d80a5 Author: Paul Colby <[email protected]> Date: Fri Jan 17 13:05:59 2025 +1100 Reduce runs of spaces to single spaces commit 5f90ee3 Author: Paul Colby <[email protected]> Date: Fri Jan 17 13:01:36 2025 +1100 Expect an appimage plugin for Linux arm64 Even though we didn't request one. Because linuxdeploy supplies one itself. commit 5ba3185 Author: Paul Colby <[email protected]> Date: Fri Jan 17 12:55:08 2025 +1100 Show actual and expected plugins commit b203e15 Author: Paul Colby <[email protected]> Date: Fri Jan 17 12:45:46 2025 +1100 Formalise the workaround for Linux arm64 issue #25 See actions/partner-runner-images#25 commit 839cdde Author: Paul Colby <[email protected]> Date: Fri Jan 17 12:34:44 2025 +1100 Strip erroneous `admin` from $PATH See actions/partner-runner-images#25 commit a6b63e5 Author: Paul Colby <[email protected]> Date: Fri Jan 17 12:18:58 2025 +1100 Inspect the $PATH commit ce2cae9 Author: Paul Colby <[email protected]> Date: Fri Jan 17 12:16:30 2025 +1100 Drop version suffix from plugin names filter commit dab148a Author: Paul Colby <[email protected]> Date: Thu Jan 16 18:18:17 2025 +1100 Filter plugins **not** supported for this arch commit 03105ce Author: Paul Colby <[email protected]> Date: Thu Jan 16 18:17:16 2025 +1100 Filter plugins not supported for this arch commit dde6cb7 Author: Paul Colby <[email protected]> Date: Thu Jan 16 18:15:09 2025 +1100 Only install Python plugin for x86_64 commit b1c7826 Author: Paul Colby <[email protected]> Date: Thu Jan 16 18:12:59 2025 +1100 Try installing ncurses and python plugins on all arch's commit 51079c5 Author: Paul Colby <[email protected]> Date: Thu Jan 16 18:09:52 2025 +1100 Use arm64 host for arm64, x86-64 hosts for the rest commit 0075a95 Author: Paul Colby <[email protected]> Date: Thu Jan 16 18:05:30 2025 +1100 Can execute on arm64 hosts now commit 81f0f2f Author: Paul Colby <[email protected]> Date: Thu Jan 16 18:03:53 2025 +1100 Correct workflow syntax commit bdf0037 Author: Paul Colby <[email protected]> Date: Thu Jan 16 18:03:32 2025 +1100 Execute the correct binary for the current host arch commit 584887d Author: Paul Colby <[email protected]> Date: Thu Jan 16 18:00:00 2025 +1100 Try out GitHub's new Linux arm64 runners Now in public preview: https://github.blog/changelog/2025-01-16-linux-arm64-hosted-runners-now-available-for-free-in-public-repositories-public-preview/
1 parent c9331d4 commit 3adee3b

File tree

2 files changed

+82
-6
lines changed

2 files changed

+82
-6
lines changed

.github/workflows/ci.yaml

Lines changed: 43 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,31 @@ jobs:
2020
test-defaults:
2121
runs-on: ${{ matrix.os }}
2222
steps:
23+
# \todo Remove this step when https://github.com/actions/partner-runner-images/issues/25 is resolved.
24+
- name: Correct broken $PATH on Linux arm64 runners
25+
if: endsWith(matrix.os, '-arm')
26+
run: sed -Ee 's/^/PATH=/' -e 's/(runner)admin/\1/g' <<< "${PATH}" | tee -a "$GITHUB_ENV"
2327
- uses: actions/checkout@v4
2428
- uses: ./
25-
- run: linuxdeploy-x86_64.AppImage --list-plugins
29+
- run: linuxdeploy-"${LINUXDEPLOY_ARCH}".AppImage --list-plugins
30+
env:
31+
LINUXDEPLOY_ARCH: ${{ endsWith(matrix.os, '-arm') && 'aarch64' || 'x86_64' }}
2632
strategy:
2733
matrix:
2834
os:
2935
- ubuntu-22.04
36+
- ubuntu-22.04-arm
3037
- ubuntu-24.04
38+
- ubuntu-24.04-arm
3139
fail-fast: false
3240

3341
test-options:
3442
runs-on: ${{ matrix.os }}
3543
steps:
44+
# \todo Remove this step when https://github.com/actions/partner-runner-images/issues/25 is resolved.
45+
- name: Correct broken $PATH on Linux arm64 runners
46+
if: endsWith(matrix.os, '-arm')
47+
run: sed -Ee 's/^/PATH=/' -e 's/(runner)admin/\1/g' <<< "${PATH}" | tee -a "$GITHUB_ENV"
3648
- uses: actions/checkout@v4
3749
- name: Define test install dir
3850
run: tee -a "$GITHUB_ENV" <<< "INSTALL_DIR=${RUNNER_TEMP}/test/linuxdeploy/bin"
@@ -69,7 +81,9 @@ jobs:
6981
matrix:
7082
os:
7183
- ubuntu-22.04
84+
- ubuntu-22.04-arm
7285
- ubuntu-24.04
86+
- ubuntu-24.04-arm
7387
fail-fast: false
7488

7589
test-plugins:
@@ -90,26 +104,45 @@ jobs:
90104
python
91105
qt
92106
steps:
107+
# \todo Remove this step when https://github.com/actions/partner-runner-images/issues/25 is resolved.
108+
- name: Correct broken $PATH on Linux arm64 runners
109+
if: endsWith(matrix.os, '-arm')
110+
run: sed -Ee 's/^/PATH=/' -e 's/(runner)admin/\1/g' <<< "${PATH}" | tee -a "$GITHUB_ENV"
93111
- uses: actions/checkout@v4
112+
- name: Filter plugins not supported for this arch
113+
run: |
114+
[[ '${{ matrix.os }}' != *-arm ]] ||
115+
PLUGINS=$(sed -Ee 's/(appimage|native_packages|python)//g' \
116+
-e 's/ +/ /g' -e 's/(^ )|( $)//' <<< "${PLUGINS}")
117+
tee -a "$GITHUB_ENV" <<< "PLUGINS=${PLUGINS}"
94118
- name: Install linuxdeploy, and all supported plugins
95119
uses: ./
96120
with:
97121
plugins: ${{ env.PLUGINS }}
98122
- name: Check installed plugins
99123
run: |
100124
ls -l "${RUNNER_TEMP}/linuxdeploy"
101-
linuxdeploy-x86_64.AppImage --list-plugins | tee "${RUNNER_TEMP}/plugins.txt"
125+
linuxdeploy-"${LINUXDEPLOY_ARCH}".AppImage --list-plugins | tee "${RUNNER_TEMP}/plugins.txt"
102126
plugins=($(sed -Ee '0,/^Available plugins:/d' -e 's/:.*//' "${RUNNER_TEMP}/plugins.txt" | sort))
103-
[[ "${plugins[@]}" = "${PLUGINS}" ]]
127+
[[ '${{ matrix.os }}' != *-arm ]] || PLUGINS="appimage ${PLUGINS}" # linuxdeploy provides an appimage plugin.
128+
[[ "${plugins[@]}" == "${PLUGINS}" ]] || {
129+
echo "Expected: '${PLUGINS}'"
130+
echo "Actual: '${plugins[@]}'"
131+
false
132+
}
133+
env:
134+
LINUXDEPLOY_ARCH: ${{ endsWith(matrix.os, '-arm') && 'aarch64' || 'x86_64' }}
104135
strategy:
105136
matrix:
106137
os:
107138
- ubuntu-22.04
139+
- ubuntu-22.04-arm
108140
- ubuntu-24.04
141+
- ubuntu-24.04-arm
109142
fail-fast: false
110143

111144
test-plugins-latest:
112-
runs-on: ${{ matrix.os }}
145+
runs-on: ${{ matrix.os }}${{ matrix.arch == 'aarch64' && '-arm' || '' }}
113146
env:
114147
# These should all be the latest official releases, however most (all?) plugins don't have official releases yet.
115148
PLUGINS: >-
@@ -127,20 +160,24 @@ jobs:
127160
python@continuous
128161
129162
steps:
163+
# \todo Remove this step when https://github.com/actions/partner-runner-images/issues/25 is resolved.
164+
- name: Correct broken $PATH on Linux arm64 runners
165+
if: matrix.arch == 'aarch64'
166+
run: sed -Ee 's/^/PATH=/' -e 's/(runner)admin/\1/g' <<< "${PATH}" | tee -a "$GITHUB_ENV"
130167
- uses: actions/checkout@v4
131168
- name: Filter plugins not supported for this arch
132169
run: |
133170
[[ '${{ matrix.arch }}' =~ ^(i386|x86_64)$ ]] ||
134171
PLUGINS=$(sed -Ee 's/appimage@[^ ]+//g' <<< "${PLUGINS}")
135172
[[ '${{ matrix.arch }}' == 'x86_64' ]] ||
136-
PLUGINS=$(sed -Ee 's/(native_packages|ncurses|python)@[^ ]+//g' <<< "${PLUGINS}")
173+
PLUGINS=$(sed -Ee 's/(native_packages|python)@[^ ]+//g' <<< "${PLUGINS}")
137174
tee -a "$GITHUB_ENV" <<< "PLUGINS=${PLUGINS}"
138175
- name: Install linuxdeploy, and all supported plugins
139176
uses: ./
140177
with:
141178
arch: ${{ matrix.arch }}
142179
plugins: ${{ env.PLUGINS }}
143-
- if: endsWith(matrix.arch, 'x86_64')
180+
- if: matrix.arch == 'aarch64' || endsWith(matrix.arch, 'x86_64')
144181
run: linuxdeploy-${{ matrix.arch }}.AppImage --list-plugins
145182
strategy:
146183
matrix:

.github/workflows/plugins.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# Supported [linuxdeploy] Plugins
2+
3+
Just a convenient list for CI development.
4+
5+
| Plugin | Architecture/s |
6+
|--------|----------------|
7+
| *Official Plugins* ||
8+
| [appimage] | `i386`, `x86_64` |
9+
| [conda] | *all* (`.sh`) |
10+
| [gstreamer] | *all* (`.sh`) |
11+
| [gtk] | *all* (`.sh`) |
12+
| [native_packages] |`x86_64` |
13+
| [ncurses] | *all* (`.sh`) |
14+
| [qt] | `aarch64`, `armhf`, `i386`, `static-x86_64`, `x86_64` |
15+
| *Official Misc Plugins* ||
16+
| [demo] | *all* (`.sh`) |
17+
| [gdb] | *all* (`.sh`) |
18+
| [gettext] | *all* (`.sh`) |
19+
| [grantlee5] | *all* (`.sh`) |
20+
| *Third-party Plugins* | |
21+
| [checkrt] | *all* (`.sh`) |
22+
| [python] | `x86_64` |
23+
24+
[linuxdeploy]: https://github.com/linuxdeploy/linuxdeploy
25+
[appimage]: https://github.com/linuxdeploy/linuxdeploy-plugin-appimage
26+
[conda]: https://github.com/linuxdeploy/linuxdeploy-plugin-conda
27+
[gstreamer]: https://github.com/linuxdeploy/linuxdeploy-plugin-gstreamer
28+
[gtk]: https://github.com/linuxdeploy/linuxdeploy-plugin-gtk
29+
[native_packages]: https://github.com/linuxdeploy/linuxdeploy-plugin-native_packages
30+
[ncurses]: https://github.com/linuxdeploy/linuxdeploy-plugin-ncurses
31+
[qt]: https://github.com/linuxdeploy/linuxdeploy-plugin-qt
32+
33+
[demo]: https://github.com/linuxdeploy/misc-plugins/tree/master/demo
34+
[gdb]: https://github.com/linuxdeploy/misc-plugins/tree/master/gdb
35+
[gettext]: https://github.com/linuxdeploy/misc-plugins/tree/master/gettext
36+
[grantlee5]: https://github.com/linuxdeploy/misc-plugins/tree/master/grantlee5
37+
38+
[checkrt]: https://github.com/darealshinji/linuxdeploy-plugin-checkrt
39+
[python]: https://github.com/niess/linuxdeploy-plugin-python

0 commit comments

Comments
 (0)