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

libvirt/kcli: defaults to Ubuntu 22.04 #1594

Merged

Conversation

wainersm
Copy link
Member

Ubuntu 22.04 packages containerd 1.7 that is the mininum required version as of CoCo 0.8.0. Updated the libvirt/kcli_cluster.sh to install Ubuntu 22.04 instead of 20.04.

There is needed to use a kcli version newer than the build of today (2023/11/21) that contains the fix to [1].

[1] karmab/kcli#619

Fixes #1593
Signed-off-by: Wainer dos Santos Moschetta wainersm@redhat.com

@wainersm
Copy link
Member Author

I tested it locally and all the tests passed! \o/ But unfortunately I lost results, so you will need to trust me :)

@wainersm wainersm added the test_e2e_libvirt Run Libvirt e2e tests label Nov 21, 2023
@wainersm
Copy link
Member Author

Added the test_e2e_libvirt label just to check the current status of CI, I don't expect it to pass (podvm build for CentOS should fail).

Copy link
Contributor

@huoqifeng huoqifeng left a comment

Choose a reason for hiding this comment

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

LGTM

@huoqifeng
Copy link
Contributor

huoqifeng commented Nov 22, 2023

Thanks @wainersm , I notice failure when push the podvm image in PR check in https://github.com/confidential-containers/cloud-api-adaptor/actions/runs/6949012011/job/18906372542?pr=1594 , looks it's not related with the PR but a token expiration? or it's expected as the PR check is running in a fork without right token?

#16 ERROR: failed to push ghcr.io/confidential-containers/podvm-binaries-centos-amd64:ci-pr1594: failed commit on ref "manifest-sha256:ed67e98f5404a3e264206af8411d22195acd5fc8c08cd0254ce9ef2a63af3491": unexpected status from PUT request to https://ghcr.io/v2/confidential-containers/podvm-binaries-centos-amd64/manifests/sha256:ed67e98f5404a3e264206af8411d22195acd5fc8c08cd0254ce9ef2a63af3491: 403 Forbidden

Copy link
Member

@liudalibj liudalibj left a comment

Choose a reason for hiding this comment

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

LGTM

@@ -100,11 +100,6 @@ jobs:
[ -f ~/.ssh/id_rsa ] || \
ssh-keygen -t rsa -f ~/.ssh/id_rsa -N ""

# Newest version of kcli does not index old Ubuntu images like 20.04
Copy link
Contributor

Choose a reason for hiding this comment

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

Btw the newest kcli does index 20.04 again thanks to Fabiano ;-) (not that it'd be important for this PR)

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.

Code LGTM. I'll try and test it out later if I get the chance

@stevenhorsman
Copy link
Member

I tested this locally - it was a bit slow, so a couple of times it timed out, but that's probably my VM. The tests all passed though once I had it set-up including nydus:

=== RUN   TestLibvirtCreateSimplePodWithNydusAnnotation/SimplePeerPod_test/PodVM_is_created
    assessment_helpers_test.go:159: Pulled with nydus-snapshotter driver:2023/11/22 10:48:20 [adaptor/proxy]         mount_point:/run/kata-containers/bf6013f46756ca54aa6179c1c34a3cce1eb4df441860a21d1081e2b002301f45/rootfs source:docker.io/library/alpine:latest fstype:overlay driver:image_guest_pull
time="2023-11-22T02:48:24-08:00" level=info msg="Deleting pod alpine..."
time="2023-11-22T02:48:29-08:00" level=info msg="Pod alpine has been successfully deleted within 60s"
--- PASS: TestLibvirtCreateSimplePodWithNydusAnnotation (115.19s)
    --- PASS: TestLibvirtCreateSimplePodWithNydusAnnotation/SimplePeerPod_test (115.19s)
        --- PASS: TestLibvirtCreateSimplePodWithNydusAnnotation/SimplePeerPod_test/PodVM_is_created (0.11s)

@wainersm wainersm mentioned this pull request Nov 22, 2023
@wainersm
Copy link
Member Author

Thanks @wainersm , I notice failure when push the podvm image in PR check in https://github.com/confidential-containers/cloud-api-adaptor/actions/runs/6949012011/job/18906372542?pr=1594 , looks it's not related with the PR but a token expiration? or it's expected as the PR check is running in a fork without right token?

#16 ERROR: failed to push ghcr.io/confidential-containers/podvm-binaries-centos-amd64:ci-pr1594: failed commit on ref "manifest-sha256:ed67e98f5404a3e264206af8411d22195acd5fc8c08cd0254ce9ef2a63af3491": unexpected status from PUT request to https://ghcr.io/v2/confidential-containers/podvm-binaries-centos-amd64/manifests/sha256:ed67e98f5404a3e264206af8411d22195acd5fc8c08cd0254ce9ef2a63af3491: 403 Forbidden

hmmm... interesting that the builder workflow was able to publish the container on quay.io. I might have introduced a bug on recent changes I made to the workflows or it might be an intermittent issue. Let me re-run the jobs to see what happens.

Ubuntu 22.04 packages containerd 1.7 that is the mininum required
version as of CoCo 0.8.0. Updated the libvirt/kcli_cluster.sh to install
Ubuntu 22.04 instead of 20.04.

There is needed to use a kcli version newer than the build of today
(2023/11/22) that contains the fix to [1][2][3].

[1] karmab/kcli#619
[2] karmab/kcli#620
[3] karmab/kcli#622

Fixes confidential-containers#1593
Signed-off-by: Wainer dos Santos Moschetta <wainersm@redhat.com>
@wainersm
Copy link
Member Author

Sending an updated version where I bumped the mininum kcli build date to 2023/11/22 to pick up @liudalibj's fixes.

I re-ran the tests with kcli-99.0.0.git.202311221027.841a950-0 on x86_64, all passed, including nydus:

=== RUN   TestLibvirtCreateSimplePodWithNydusAnnotation/SimplePeerPod_test/PodVM_is_created
    assessment_helpers_test.go:159: Pulled with nydus-snapshotter driver:2023/11/22 13:18:53 [adaptor/proxy]         mount_point:/run/kata-containers/456b020f20ce57ae8003a57c1b719b0ce24fd2d86c862eb58e9bdad5da247f73/rootfs source:docker.io/library/alpine:latest fstype:overlay driver:image_guest_pull
time="2023-11-22T10:18:59-03:00" level=info msg="Deleting pod alpine..."
time="2023-11-22T10:19:04-03:00" level=info msg="Pod alpine has been successfully deleted within 60s"
--- PASS: TestLibvirtCreateSimplePodWithNydusAnnotation (45.15s)
    --- PASS: TestLibvirtCreateSimplePodWithNydusAnnotation/SimplePeerPod_test (45.15s)
        --- PASS: TestLibvirtCreateSimplePodWithNydusAnnotation/SimplePeerPod_test/PodVM_is_created (0

@wainersm wainersm merged commit 6713f65 into confidential-containers:main Nov 22, 2023
25 of 28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Libvirt e2e with kcli no longer works since CoCo 0.8.0
5 participants