-
Notifications
You must be signed in to change notification settings - Fork 65
controllers: Validates kata version aginst the Kata RPM version present in the extension image. #1514
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
base: devel
Are you sure you want to change the base?
Conversation
|
Hi @ANJANA-A-R-K. Thanks for your PR. I'm waiting for a openshift member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions 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-sigs/prow repository. |
2e4e9ba to
6d1a98e
Compare
7828ce1 to
fb40a9b
Compare
…nt in the extension image. The extension image contains the Kata RPM. Extension images vary with the OCP version, which means the Kata version can change across releases, Kata version specified in the YAML must match the version bundled in the extension image. Signed-off-by: ANJANA-A-R-K <[email protected]>
fb40a9b to
99eb610
Compare
|
After discussing with @ajaypvictor on slack, let's revisit the problem. The current flow mandates the user to provide the addons image that contains both the guest environment and the IBM SE kernel. This includes the kata agent that should match the kata shim on the host, otherwise undefined and hard to debug behavior is likely to happen. This is different from all other cases where OSC and the kata-containers RPM already ensure that kata is de facto the same. My concern with this PR is that it adds an explicit version of kata that will need to be properly maintained just for this case and it doesn't even actually ensure that the user provided image is safe to use. The only way would be having the user to provide the kata version along with the addons image. The image format from Another option could be to revisit the design so that the user isn't responsible to provide the appropriate kata agent. Roughly, something like :
There are probably some challenges but it would definitely reduce the risk of inconsistency. |
|
For the s390x case, the addon image will go with including a version file, for example: { This version.json is generated by the same build pipeline that produces the kata agent/initrd and the addon image, so it reflects the exact Kata version the image was built against. Early in the OSC install flow (while installing extension image), if an addon image is present, OSC will extract just this version.json from the addon image and read the declared Kata version. It will then compare that value with the kata-containers RPM version installed on the host. If the versions match, installation proceeds as today. If they don't, OSC fails early with a clear error instead of allowing a incompatible kata agent |
For the s390x case, the addon image will include a version json which contains the kata version. Compare the version present in extension image with the version of kata in the add on image Signed-off-by: ANJANA-A-R-K <[email protected]>
84d5071 to
a142cd1
Compare
|
I see you kept the original patch and added another one on top to introduce the version JSON file.
For now, please squash the two commits into a single one. I'll start reviewing when it is done. |
The extension image contains the Kata RPM. Extension images vary with the OCP version, which means the Kata version can change across releases. To ensure correctness, we must verify that the Kata version specified in the YAML matches the version bundled in the extension image.
This change adds an explicit Kata version field to the controller YAML and validates it against the Kata RPM version present in the extension image.
Current behavior
If the addon artifact image is not updated and the OSC version remains the same, this can introduce a new Kata RPM version even though:
As a result, when customers upgrade OCP but continue using an older addon artifact image, OSC may silently install a Kata version that:
Upgrade scenario
Currently, this mismatch happens silently, with no validation or guardrails.
This PR adds an explicit validation step to prevent unintended Kata version drift:
During reconciliation:
https://issues.redhat.com/browse/KATA-4557