Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add functionality for running tests on a remote machine #626

Open
wants to merge 13 commits into
base: seabios-support
Choose a base branch
from

Conversation

pietrushnic
Copy link
Contributor

This commit introduces a new feature that allows users to run tests on a remote machine. This is particularly useful when running QEMU on the local machine is not desirable due to security concerns or memory limitations.

The changes include updates to the documentation to explain the new feature and a new script, remote-runner.sh, which handles the synchronization of a local directory to a remote machine and the execution of QEMU based on parameters on the remote machine.

@pietrushnic pietrushnic requested a review from macpijan December 3, 2024 23:11
@pietrushnic pietrushnic force-pushed the support-for-qemu-run-on-remote-machine branch from 1f22fac to 9fdc43c Compare December 14, 2024 23:09
This commit introduces a new feature that allows users to run tests on a
remote machine. This is particularly useful when running QEMU on the
local machine is not desirable due to security concerns or memory
limitations.

The changes include updates to the documentation to explain the new
feature and a new script, `remote-runner.sh`, which handles the
synchronization of a local directory to a remote machine and the
execution of QEMU based on parameters on the remote machine.

Signed-off-by: Piotr Król <[email protected]>
@pietrushnic pietrushnic force-pushed the support-for-qemu-run-on-remote-machine branch from 9fdc43c to 22cd658 Compare December 14, 2024 23:40
This commit refactors the qemu-run.sh and remote-runner.sh scripts to
improve their flexibility and usability.

In qemu-run.sh, the ACTION parameter has been split into ACTION and
FIRMWARE parameters. This allows the user to specify the action (os or
os_install) and the firmware (uefi or seabios) separately, providing
more flexibility in the configuration of the QEMU instance. The usage
instructions have been updated accordingly. Now we are not limited to
run tests or install only on uefi.

In remote-runner.sh, the number of required parameters has been
increased from 4 to 5 to accommodate the new FIRMWARE parameter in
qemu-run.sh. The usage instructions and error messages have been updated
to reflect this change.

Additionally, the shebang in remote-runner.sh has been changed from
different systems.

Signed-off-by: Piotr Król <[email protected]>
@pietrushnic pietrushnic changed the base branch from seabios-support-for-network-boot-tests to seabios-support December 16, 2024 00:42
It is very interesting that incorrect pattern fails because of
underlying logic:

KEYWORD ${matches} = BuiltIn . Run Keyword And Return Status Should Match, ${item}, *${option}*
Documentation:

23:12:21.311 	TRACE 	Arguments: [ '2. AHCI/0: QEMU HARDDISK ATA-7 Hard-Disk (20480 MiBytes)' | '*[setup]*' ]
23:12:21.311 	TRACE 	Return: None
23:12:21.311 	TRACE 	Return: True
23:12:21.311 	INFO 	${matches} = True

So this one return True, but following one return False:

KEYWORD ${matches} = BuiltIn . Run Keyword And Return Status Should Match, ${item}, *${option}*
Documentation:

Fails if the given string does not match the given pattern.
Start / End / Elapsed: 	20241216 23:12:21.307 / 20241216 23:12:21.309 / 00:00:00.002
23:12:21.307 	TRACE 	Arguments: [ '1. DVD/CD [AHCI/2: QEMU DVD-ROM ATAPI-4 DVD/CD]' | '*[setup]*' ]
23:12:21.308 	FAIL 	'1. DVD/CD [AHCI/2: QEMU DVD-ROM ATAPI-4 DVD/CD]' does not match '*[setup]*'
23:12:21.309 	DEBUG 	Traceback (most recent call last):
  None
AssertionError: '1. DVD/CD [AHCI/2: QEMU DVD-ROM ATAPI-4 DVD/CD]' does not match '*[setup]*'
23:12:21.309 	TRACE 	Return: False
23:12:21.309 	INFO 	${matches} = False

Signed-off-by: Piotr Król <[email protected]>
This patch fix the problem where virtio-net by delivering its pxe rom
interfere with the fact that seabios needs empty romfile and use built
in iPXE to do network boot and work with developed tests.

Signed-off-by: Piotr Król <[email protected]>
…ers in env variables no mater the QEMU_FW_FILE

Signed-off-by: Piotr Król <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant