-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
sidecar to inject qemu args #11876
base: main
Are you sure you want to change the base?
sidecar to inject qemu args #11876
Conversation
Adding the "do-not-merge/release-note-label-needed" label because no release-note block was detected, please follow our release note process to remove it. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Hi @ibrokethecloud. Thanks for your PR. PRs from untrusted users cannot be marked as trusted with I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
…tions on vmi Signed-off-by: Gaurav Mehta <gaurav.mehta@suse.com>
272ed06
to
823fe5a
Compare
I wrote one in the past too, see #9166 (comment) |
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.
You might be able to write this in python and attach to a configmap and enable it with annotation, instead of having to build a container image.
|
||
vmSchema "kubevirt.io/api/core/v1" | ||
|
||
"kubevirt.io/kubevirt/pkg/virt-launcher/virtwrap/api" |
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.
If the PR is to be accepted, I'd use libvirtxml instead. This makes the sidecar easy to build out-of-tree. See this one which is not merged yet: #11846
@ibrokethecloud this should be doable with the configmap that @victortoso mentioned. I would avoid to add an new image. On the other hand, I think we are missing the documentation how to achieve it, @victortoso am I correct? If so, would you mind to add the example in the user guide? |
Hi @alicefr and @ibrokethecloud I created a simple python script to add qemu env/args using sidecars + configmap and published it as a gist:
I'll propose adding it in the user-guide later Today. Just for clarification, the steps using this example are:
Cheers, |
What this PR does
Before this PR:
PR introduces an additional sample sidecar to inject additional qemu args to the domain definition, based on annotations present on the VMI.
After this PR:
Users can fine tune qemu args in the domain definition to control specific behavior.
Fixes #
#11093
Why we need it and why it was done in this way
The following tradeoffs were made:
The sidecar approach seems the least disruptive means to perform this operation without changing core kubevirt api to allow inject of random qemu arguments.
The following alternatives were considered:
Links to places where the discussion took place:
Please refer to conversation from here: #11093 (comment)
Special notes for your reviewer
Checklist
This checklist is not enforcing, but it's a reminder of items that could be relevant to every PR.
Approvers are expected to review this list.
Release note