CI: migrate Vagrant to Lima#13728
Conversation
There was a problem hiding this comment.
Pull request overview
This PR migrates the Linux VM-based CI integration job from Vagrant/libvirt to Lima, and moves the former Vagrant provision/test logic into reusable shell scripts under script/lima/.
Changes:
- Remove the top-level
Vagrantfileand the legacy Vagrant root-resize helper. - Add Lima guest provisioning and test runner scripts (
script/lima/*) plus usage documentation. - Update
.github/workflows/ci.ymlto replace theintegration-vagrantjob withintegration-limausinglima-vm/lima-actions/setup.
Reviewed changes
Copilot reviewed 9 out of 10 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
Vagrantfile |
Removed Vagrant-based VM provisioning and test orchestration. |
script/resize-vagrant-root.sh |
Removed Vagrant-specific root filesystem resize helper. |
script/lima/provision.sh |
New guest provisioning script for installing dependencies, Go, runc/CNI/cri-tools, containerd, SELinux config. |
script/lima/test-integration.sh |
New Lima guest runner for make integration and a targeted Go test. |
script/lima/test-cri-integration.sh |
New Lima guest runner for CRI integration test script. |
script/lima/test-cri.sh |
New Lima guest runner for critest against systemd-managed containerd. |
script/lima/README.md |
Documentation for local usage and supported environment variables. |
.gitignore |
Stop ignoring .vagrant/ since Vagrant is removed. |
.github/workflows/release/Dockerfile.dockerignore |
Stop ignoring .vagrant/ in release Docker build context. |
.github/workflows/ci.yml |
Replace the Vagrant-based integration job with a Lima-based matrix job. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
samuelkarp
left a comment
There was a problem hiding this comment.
This generally looks good. And seems slightly faster.
Vagrant is no longer well maintained: e.g., its apt repository does not provide packages for Ubuntu 26.04 (hashicorp/vagrant#13811), and recent Fedora boxes are no longer published to HashiCorp's registry, so the CI had to download the box file manually from Fedora mirrors. The test scripts in the Vagrantfile were split out to script/vm/*.sh . The scripts depend on neither Vagrant nor Lima, and can be used with other VM environments too. Assisted-by: Claude Fable 5 <[email protected]> Signed-off-by: Akihiro Suda <[email protected]>
Claude says "You're absolutely right" 😂 |
|
/cherry-pick release/1.7 |
|
@AkihiroSuda: once the present PR merges, I will cherry-pick it on top of DetailsIn 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-sigs/prow repository. |
|
@AkihiroSuda: #13728 failed to apply on top of branch "release/2.0": DetailsIn 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-sigs/prow repository. |
|
@AkihiroSuda: #13728 failed to apply on top of branch "release/2.2": DetailsIn 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-sigs/prow repository. |
|
@AkihiroSuda: #13728 failed to apply on top of branch "release/2.3": DetailsIn 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-sigs/prow repository. |
|
@AkihiroSuda: #13728 failed to apply on top of branch "release/1.7": DetailsIn 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-sigs/prow repository. |
| run: lima sudo CGROUP_DRIVER="$CGROUP_DRIVER" RUNC_FLAVOR="$RUNC_FLAVOR" script/vm/test-cri-integration.sh | ||
| - name: test-cri | ||
| run: sudo BOX=$BOX CGROUP_DRIVER=$CGROUP_DRIVER RUNC_FLAVOR=$RUNC_FLAVOR vagrant up --provision-with=selinux,install-runc,install-gotestsum,test-cri | ||
| run: lima sudo CGROUP_DRIVER="$CGROUP_DRIVER" script/vm/test-cri.sh |
There was a problem hiding this comment.
(RUNC_FLAVOR=$RUNC_FLAVOR seems omitted here, but it doesn't seem to matter?)
Fix #13727
The test scripts in the Vagrantfile were split out to
script/vm/*.sh. The scripts depend on neither Vagrant nor Lima, and can be used with other VM environments too.Assisted-by: Claude Fable 5 [email protected]