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
Bug 1820401: daemon: better way to find installed kernel-rt packages on host #1612
Conversation
/hold |
35d5999
to
9dd6816
Compare
@sinnykumari: This pull request references Bugzilla bug 1820401, which is valid. The bug has been moved to the POST state. The bug has been updated to refer to the pull request using the external bug tracker. 3 validation(s) were run on this bug
In response to this:
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. |
/hold cancel |
Just a nit @cgwalters ptal as well if you have some time /approve |
@sinnykumari: This pull request references Bugzilla bug 1820401, which is valid. 3 validation(s) were run on this bug
In response to this:
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. |
Initially we were relying on fixed set of kernel-rt sub-packages which will be installed on the system. This can cause issues when machine-os-content ships additional kernel-rt sub-packages. To solve this, we now query host with `rpm-ostree status --json` and look for requested-local-packages in the 0th index from available deployments list. Fixes: RHBZ#1820401
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.
Overall this is fine to merge as is if it's fixing CI. But, a few comments that could be done as followup.
Nice work on this!
|
||
rtRegex := regexp.MustCompile("kernel-rt-.*") | ||
for _, localPkg := range rpms.Deployments[0].RequestedLocalPkgs { | ||
if rtRegex.MatchString(localPkg) { |
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.
This could just be strings.HasPrefix(localPkg, "kernel-rt-")
. But fine as is too.
@@ -50,6 +50,38 @@ const ( | |||
realtimeKernelType = "realtime" | |||
) | |||
|
|||
// HostInfo contains information of an OSTree based system | |||
type HostInfo struct { |
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.
We already have rpmOstreeState
in rpm-ostree.go
; would be good to share code there.
Thanks Colin for review! Agree with you to unblock the CI test first. Will address the review comments in follow-up PR |
/retest |
1 similar comment
/retest |
ugh, these failing ci tests |
/retest |
1 similar comment
/retest |
/lgtm let's address Colin's address in a follow up! |
maybe... /lgtm |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: cgwalters, runcom, sinnykumari The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@sinnykumari: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. 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. I understand the commands that are listed here. |
/skip |
Checked into live cluster from e2e-gcp-op CI test run, kernelType test went fine. e2-gcp-op test should finish fine |
@sinnykumari: All pull requests linked via external trackers have merged: openshift/machine-config-operator#1612. Bugzilla bug 1820401 has been moved to the MODIFIED state. In response to this:
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. |
… info Make GetBootedDeployment() function from rpm-ostree.go public so that it can be reused. Also update test accordingly. Follow-up from PR openshift#1612
Initially we were relying on fixed set of kernel-rt
sub-packages which will be installed on the system. This can cause
issues when machine-os-content ships additional kernel-rt
sub-packages.
To solve this, we now query host with
rpm-ostree status --json
and look for requested-local-packagesin the 0th index from available deployments list.
Fixes bug - https://bugzilla.redhat.com/show_bug.cgi?id=1820401