Skip to content

Commit

Permalink
ghactions: Use ubuntu runner for tests
Browse files Browse the repository at this point in the history
M1 macos runners can't build our test code, and the M1 runners don't
support nested virt, which is required by `make test`
Since I expect in the future the x86_64 macos runners to go away, and
since the ubuntu runners now support nested virt, this commit uses an
ubuntu runner to run `make test`.

This fixes #358

Signed-off-by: Christophe Fergeau <[email protected]>
  • Loading branch information
cfergeau committed May 16, 2024
1 parent 4217481 commit 4fae323
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,24 +38,25 @@ jobs:
path: bin/*

tests:
runs-on: macos-latest # Only Mac runners support nested virt
runs-on: ubuntu-latest # The runner must support nested virt
needs: build # Don't bother testing if cross arch build fails
timeout-minutes: 30
steps:
- uses: actions/checkout@v4

- name: Install
- name: Install qemu
run: |
brew install qemu
touch continue
sudo apt install qemu-kvm
sudo usermod -a -G kvm $USER
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.20.x
go-version: stable

- name: Test
run: make test
run: |
sudo -s -u ${USER} bash -c 'make test'
- uses: actions/upload-artifact@v4
if: always()
Expand Down

0 comments on commit 4fae323

Please sign in to comment.