Implement feature toggle for GA forwarding mode in QEMU#3255
Implement feature toggle for GA forwarding mode in QEMU#3255arixmkii wants to merge 2 commits intolima-vm:masterfrom
Conversation
|
Replaces #3148 Edit: fixed link |
|
Converted to Draft. The code looks legit, but I haven't done manual testing, nor I had time to integrate it with my CI builds for Windows. Publishing it for some early reviews to collect feedback that I'm not doing something absolutely stupid. Edit. I'm sorry for pushing this with broken unit tests. I'm still getting used to codebase. |
|
|
||
| type QEMUOpts struct { | ||
| MinimumVersion *string `yaml:"minimumVersion,omitempty" json:"minimumVersion,omitempty" jsonschema:"nullable"` | ||
| VirtioGA *bool `yaml:"virtioGA,omitempty" json:"virtioGA,omitempty" jsonschema:"nullable"` |
There was a problem hiding this comment.
Maybe this should be guestAgentTransportType *string ?
Also, this may potentially apply to non-QEMU VM drivers?
There was a problem hiding this comment.
Good call! I will check if this could be applicable for other platforms. Having it as typed option instead of boolean flag feels like a better design.
Current code supports 2 modes: - forwarding via SSH forwarding - forwarding by QEMU via serialport In GA they are exclusive modes - it either talks to device or exposes Unix socket inside VM. At some point the GA part was switched to Unix socket only, but QEMU start command line was not updated. SSH forwarder takes care of it by removing Unix socket before starting its own, but there is no point in having it, when it can't be used. This code introduces feature toggle allowing to use either mode. Keeping the "unstable" option could be beneficial for environments, where Unix socket forwarding is tricky (Windows hosts). Signed-off-by: Arthur Sengileyev <arthur.sengileyev@gmail.com>
Signed-off-by: Arthur Sengileyev <arthur.sengileyev@gmail.com>
24eaf3b to
2d5c774
Compare
|
I rebased it, because I believe it still has value before a more complete feature is implemented as requested in review. I also enabled QEMU integration tests to prove that this actually work (after all previous patches merged already). I had to disable mount tests for QEMU on Windows, because it would need at least these changes: |
|
|
Fixes #3177
Current code supports 2 modes:
In GA they are exclusive modes - it either talks to device or exposes Unix socket inside VM.
At some point the GA part was switched to Unix socket only, but QEMU start command line was not updated. SSH forwarder takes care of it by removing Unix socket before starting its own, but there is no point in having it, when it can't be used.
This code introduces feature toggle allowing to use either mode. Keeping the "unstable" option could be beneficial for environments, where Unix socket forwarding is tricky (Windows hosts).