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
libvirt: support proper networking in user session #53204
Conversation
5582c46
to
05df6a7
Compare
Thanks @volth - how about this version? |
Any reservations @infinisil ? |
environment = { | ||
# this file is expected in /etc/qemu and not sysconfdir (/var/lib) | ||
etc."qemu/bridge.conf".text = (lib.concatStringsSep "\n" (map (e: | ||
"allow ${e}") cfg.allowedBridges)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
{
etc."qemu/bridge.conf".text = lib.concatMapStringsSep "\n" (e: "allow ${e}") cfg.allowedBridges;
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, fixed.
Description updated. Any other concerns or are we good to go? If you want the module fine-tuned, can we at least merge the change to derivation? I've been carrying this change on my side for a while and it causes a bunch of stuff to be rebuilt instead of just fetching from the cache. |
As I haven't heard any strong reservations, I'm taking the liberty of merging this. |
Motivation for this change
With the help of
qemu-bridge-helper
it's possible for VMs run underqemu:///session
to have proper network access and not resort to user mode networking.In my case that means I can dump VirtualBox!
I am not sure ifWe are using"QEMU_PR_HELPER=/run/current-system/sw/bin/qemu-pr-helper"
is really the best way to pass in the path to the PR helper but since the qemu package to use is configurable, we need a global path.QEMU_PR_HELPER=/run/libvirt/nix-helpers/qemu-pr-helper
based on @volth's feedback.Cc: @fpletz
Things done
sandbox
innix.conf
on non-NixOS)nix-shell -p nox --run "nox-review wip"
./result/bin/
)nix path-info -S
before and after)