Skip to content
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

rootfs: confidential: Install coco-guest-components #9022

Conversation

fidencio
Copy link
Member

@fidencio fidencio commented Feb 5, 2024

Let's install the coco-guest-components into the confidential rootfs image and initrd.

Fixes: #9021

@fidencio fidencio added ok-to-test merge-to-main PRs relating to merging CCv0 content to main labels Feb 5, 2024
@katacontainersbot katacontainersbot added the size/small Small and simple task label Feb 5, 2024
@fidencio fidencio marked this pull request as draft February 5, 2024 11:04
@fidencio fidencio force-pushed the topic/add-guest-components-to-the-confidential-image-and-initrd branch from 53e4dea to a21c27b Compare February 5, 2024 11:24
@fidencio fidencio force-pushed the topic/add-guest-components-to-the-confidential-image-and-initrd branch from a21c27b to d617d1b Compare February 5, 2024 11:47
Copy link
Member

@stevenhorsman stevenhorsman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks

As DESTDIR was not being passed, we've been installing the final
binaries in a container path that was not exposed to the host, leading
to creating an empty tarball with the guest components.

Now, theoretically, guest-components should respect a PREFIX passed, but
that's not the case and we're manually adding "/usr/local/bin" to the
passed DESTDIR.

Here's the result of the tarball:
```bash
⋊> kata-containers ≡ tar tf build/kata-static-coco-guest-components.tar.xz
./
./usr/
./usr/local/
./usr/local/bin/
./usr/local/bin/confidential-data-hub
./usr/local/bin/attestation-agent
./usr/local/bin/api-server-rest
```

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
@fidencio fidencio force-pushed the topic/add-guest-components-to-the-confidential-image-and-initrd branch 2 times, most recently from 3bb188b to 562afc7 Compare February 5, 2024 13:08
We need to pass this to the container where the rootfs is built, so it
can actually be unpacked inside the rootfs.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
This will make our lives easier to figure out whether the components are
being installed or not.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
Let's install the coco-guest-components into the confidential rootfs
image and initrd.

Fixes: kata-containers#9021

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
@fidencio fidencio force-pushed the topic/add-guest-components-to-the-confidential-image-and-initrd branch from 562afc7 to 27e7974 Compare February 5, 2024 13:41
@katacontainersbot katacontainersbot added size/medium Average sized task and removed size/small Small and simple task labels Feb 5, 2024
@fidencio fidencio marked this pull request as ready for review February 5, 2024 15:20
@fidencio
Copy link
Member Author

fidencio commented Feb 5, 2024

/test

@fidencio fidencio merged commit ffa1908 into kata-containers:main Feb 5, 2024
288 of 298 checks passed
Copy link
Member

@ryansavino ryansavino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, meant to get to this sooner. I looked over the changes and LGTM.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merge-to-main PRs relating to merging CCv0 content to main ok-to-test size/medium Average sized task
Projects
None yet
Development

Successfully merging this pull request may close these issues.

rootfs: confidential: Add the coco-guest-components
5 participants