avocado
avocado copied to clipboard
Bootstrap of spawner environments
Is your feature request related to a problem? Please describe.
In the nrunner architecture, a spawner will manage the execution of a task in a given environment. This environment may be the local machine (as in the ProcessSpawner
) or a separate (physical or virtual) machine (as in the PodmanSpawner
, LXCSpawner
and RemoteSpawner
).
With all of those spawners, it's assumed that Avocado will be able to query the Python version available, so that the correct egg file will be fetched/cached/deployed. This means that Python itself must be present in that environment. But, there are a good number of popular environments which do not have Python available. One that is very important to Avocado is CentOS Stream 8 (and related EL 8 systems).
Note: Currently, setuptools
is also an Avocado dependency, but work is underway to remove that dependency, so this issue focus solely on bootstrap Python itself for now.
Describe the solution you'd like
The installation of Python itself should be straightforward in many environments that support packages. A command such as dnf -y install python38
, for instance, should be enough in a CentOS Stream 8 environment.
Thus, the solution I'd like to see is one that adds Python bootstrapping support for some known environments and allows for the caching of such bootstrapping. For instance, in the case of PodmanSpawner
, there should be a requirement cache entry stating that a given local image already contains the bootstrapped environment.
Describe alternatives you've considered The only alternative is really to require the bootstrap to be done in advance, either manually or using other tools (such as the creation/update of containers in CI environments).