test: precreate cvi for e2e tests#2103
Open
universal-itengineer wants to merge 34 commits intomainfrom
Open
Conversation
c38b025 to
636d591
Compare
853e2fb to
9abdc69
Compare
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
d55ba57 to
2f8064f
Compare
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
Signed-off-by: Nikita Korolev <nikita.korolev@flant.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Migrate e2e tests from per-test VirtualImage/ClusterVirtualImage creation via HTTP sources to a shared set of precreated ClusterVirtualImages that are bootstrapped once before the suite and reused across runs. Also refactors cloud-init configuration into a typed Go struct and removes ~30 duplicated YAML manifests from testdata.
Why do we need it, and what problem does it solve?
What is the expected result?
Precreated shared CVIs: 12
ClusterVirtualImageresources (Alpine UEFI/BIOS, Alpine Perf variants, Ubuntu, Ubuntu ISO, Cirros, Debian, container images, test data) are created once inSynchronizedBeforeSuite. If CVIs already exist in the cluster from a previous run, they are reused without re-creation, making repeated local runs significantly faster.Tests migrated to precreated CVIs: All e2e tests (VM, legacy, blockdevice, snapshot, vmop suites) now create VirtualDisks and VirtualImages via
dataSource.objectRefreferencing precreated CVIs instead of downloading images over HTTP. Helper functionsNewVDFromCVIandNewGeneratedVIFromCVIare added to simplify construction.Removed ~30 duplicated YAML manifests: Per-test VI/CVI kustomize manifests are deleted from testdata directories of affinity-toleration, complex-test, disk-resizing, image-hotplug, vd-snapshots, vm-disk-attachment, vm-evacuation, vm-label-annotation, vm-migration-cancel, and vm-migration.
Typed cloud-init configuration: User-data is now generated from a
CloudConfigGo struct with OS-specific presets (AlpineCloudInit,UbuntuCloudInit,PerfCloudInit), each with correct package names and service management commands. Covered by unit tests.Controlled cleanup: Precreated CVIs are preserved between runs by default. Deletion is opt-in via the
PRECREATED_CVI_CLEANUP=yesenvironment variable.Removed unused test: Deleted
vm/hotplug_pod.go.Checklist
Changelog entries