-
Notifications
You must be signed in to change notification settings - Fork 1.2k
agent: fix startup when guest_components_procs is set to none #10583
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
agent: fix startup when guest_components_procs is set to none #10583
Conversation
Although this is a valid approach, I wonder if we shouldn't move the check from https://github.com/kata-containers/kata-containers/pull/10583/files#diff-ed2edc9fa74154f8f6bbe195c07e456a861f1c9e20e0b07a1c66d2aed49a3f0cL460 to be the first thing done as part of the @mkulke, thoughts? |
If we do this, there would be no initialization for attestation-related things (specifically: no cdh-client & no ocicrypt config) if |
You tell me. :-) |
well, the param doesn't specify whether you use guest_components, it specifies whether kata should start those guest-components processes. I guess the intention of that param was originally to have a single rootfs with all guest-component binaries, but the option to e.g. not start CDH (but only AA). GuestComponentProcs::None was just added to not start any GC process (not even AA) as kata child-process (because all, including that one are managed by systemd in peerpod). I think, now with a hard dependency on CDH, this gets more questionable. We could just have 2 options: SpawnGuestComponentProcesses=true/false I think the granularity of the GuestComponentProcs enum is not required anymore. maybe there is a usecase for not launching ASR, but then we could have this in a discrete flag. |
Okay, so, what I'd suggest then is to take this discussion outside of the context of this PR and, if you're fine with this PR as it is, we can get it merged, and continue the discussion on the flags / enum on Slack / on a different issue. Sounds fair? And sorry for adding a comment that triggered this whole discussion. :-) |
regarding the fix in this PR. you will only see this warning in the case that someone sets |
yes. I think this make sense to bundle this with final picture of the initdata design. This will drive the requirements and then we can revisit this. |
@squarti there seems to be formatting error, can you run also, can you open an issue on the CAA repo describing your non-coco scenario, so we can accommodate this? the attestation components will be more and more integrated with the evolving initdata design and it's likely that there will be future breakage if guest-components are not available and running. |
This PR ensures that OCICRYPT_CONFIG_PATH file is initialized only when CDH socket exists. This prevents startup error if attestation binaries are not installed in PodVM. Fixes: kata-containers#10568 Signed-off-by: Silenio Quarti <silenio_quarti@ca.ibm.com>
768d57b
to
1230bc7
Compare
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.
LGTM. Thanks @squarti!
Based on @fidencio's above comments to separate the discussion on the longer term need/re-working of the config to a separate issue, I think we are good to merge this now. |
This PR ensures that OCICRYPT_CONFIG_PATH file is initialized only when CDH socket exists. This prevents startup error if attestation binaries are not installed in PodVM.
Fixes: #10568