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

Bootstrap of spawner environments #5865

Open
clebergnu opened this issue Feb 5, 2024 · 1 comment
Open

Bootstrap of spawner environments #5865

clebergnu opened this issue Feb 5, 2024 · 1 comment

Comments

@clebergnu
Copy link
Contributor

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).

@clebergnu
Copy link
Contributor Author

This was driven by autils' requirement for setting up environments such as CentOS Stream 8 which lack Python 3 installed by default.

The alternative solution that will be pursued right now is to allow for the autils module metadata to allow for something like:

supported_platforms:
  - CentOS Stream 9
  - Fedora 36
  - Fedora 37
  - CentOS Stream 8
    - container_image: path_to_centos_stream_with_python/8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Long Term (Next Q) Backlog
Development

No branches or pull requests

3 participants