Require one of the lxd or lxd-installer debs or the lxd snap for the virtualization tests. (BugFix) #1181
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
Noble does not provide the lxd snap by default now in the server images, instead it provides a wrapper called lxd-installer that triggers the snap install the first time a user tries using either the lxc or lxd commands.
The jobs were not looking for the lxd-installer package, instead they were looking for the lxd snap or the old lxd package. This changes the constraints so that the jobs will run if only lxd-installer is present (on noble server) . In this case, the 'lxd init' commands that virtualization.py runs will trigger the snap install on server, and then tests proceed as expected.
Added a check to run the job if lxd-installer is on the system, since on Noble, the lxd snap and deb will not be there at first.
Resolved issues
#1022
CHECKBOX-1275
Documentation
NO docs changes needed.
Tests
Manually modified jobs.pxu on a fresh noble install to add the package lxd-installer to the requires section for the virtualization jobs.
Ran test-virtualization to call both lxd and lxdvm tests.
Before changes, the tests are skipped because the lxd snap is not installed.
After the changes, the tests are executed.