From b5df5883360833b674a2bcd887a34b75d2a279c8 Mon Sep 17 00:00:00 2001 From: Anton Hvornum Date: Tue, 14 May 2024 17:08:18 +0200 Subject: [PATCH] Attempting to limit runner to set users --- .github/workflows/iso-build.yaml | 2 +- .github/workflows/qemu-tests.yaml | 4 +++- tests/qemu/runners.py | 6 +++++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/iso-build.yaml b/.github/workflows/iso-build.yaml index 634660ce..a55d0383 100644 --- a/.github/workflows/iso-build.yaml +++ b/.github/workflows/iso-build.yaml @@ -28,7 +28,7 @@ jobs: steps: - uses: actions/checkout@v4 - run: pwd - - run: find . + - run: echo "Building for $env:GITHUB_ACTOR" - run: cat /etc/os-release - run: pacman-key --init - run: pacman --noconfirm -Sy archlinux-keyring diff --git a/.github/workflows/qemu-tests.yaml b/.github/workflows/qemu-tests.yaml index c4feb7cb..24224849 100644 --- a/.github/workflows/qemu-tests.yaml +++ b/.github/workflows/qemu-tests.yaml @@ -7,6 +7,7 @@ on: jobs: run-qemu: name: qemu testbench + if: ${{ github.actor == 'torxed' }} runs-on: self-hosted steps: - uses: actions/checkout@v4 @@ -29,10 +30,11 @@ jobs: EOF - run: pwd - run: cp /usr/share/ovmf/x64/OVMF_VARS.fd ./tests/qemu/OVMF_VARS.fd + - run: rm ./tests/qemu/archtest.img - run: qemu-img create -f qcow2 ./tests/qemu/archtest.img 10G - run: tree - run: cat .screenrc_test - - run: script -c "screen -c .screenrc_test" + - run: script -c "resize -s 24 80 && stty rows 24 && stty cols 80 && screen -c .screenrc_test" - uses: actions/upload-artifact@v4 with: name: archtest-pci_emulation diff --git a/tests/qemu/runners.py b/tests/qemu/runners.py index fcdbc870..16515b1a 100644 --- a/tests/qemu/runners.py +++ b/tests/qemu/runners.py @@ -1,5 +1,6 @@ import threading import time +import os import logging import asyncio from testbase import TestBase @@ -169,4 +170,7 @@ class TestLeaveAllDefault(TestBase): self.exit_code = 0 break - time.sleep(0.25) \ No newline at end of file + time.sleep(0.25) + + os.system('pkill tail') + exit(self.exit_code) \ No newline at end of file