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

Refactor runner declarations should use the submodule system, to allow for greater flexibility #338

Open
MaeIsBad opened this issue Feb 23, 2025 · 0 comments

Comments

@MaeIsBad
Copy link

While experimenting with the newly merged amdgpu native contexts using microvm I've found that microvm is quite inflexible for users who want to modify it's behavior. In this case I found that in order to prevent microvm from setting -nographic I had to set graphics.enable = true, which causes microvm to set -device "virtio-vga-gl", which is incompatible with -device virtio-gpu-gl.

Using the qemu runner as an example, but this would also apply to others.

Instead of the current setup, where the qemu runner declaration is one big function that creates a command from microvm configuration options, it might be sensible to instead have the qemu runner expose a "microvm.qemu.args" option(the same as the existing extraArgs) as well as a readonly command option, with other modules using the option to configure qemu.

This would already allow users to remove any problematic arguments by doing a hack, like:

      options.microvm.qemu.args = lib.mkOption { apply = lib.subtractLists [ "-device virtio-vga-gl" ]; };

but the real improvements would be in the ability to further create helper options, like for example microvm.qemu.devices.*, allowing overwriting the options configured for any device.

I'd be up for implementing the changes if @astro would be willing to merge them

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

No branches or pull requests

1 participant