Description of problem:
I've introduced a problem when it comes to OpenStack provisioning in https://gerrit.beaker-project.org/#/c/6054/5/Server/bkr/server/model/scheduler.py
The code checks if the installation.tree_url is iPXE compatible. The problem is, that a NFS URL from the distro_tree could be set on the installation.tree_url during provisioning which would mean that if no physical systems match, no OpenStack provisioning would take place.
What the code should do instead is what I do in this re-factoring https://gerrit.beaker-project.org/#/c/6057/5/Server/bkr/server/model/scheduler.py on line 3092:
* first lookup the tree URL from the lab controller
* if the tree_url is still None or does not have an http, ftp scheme it is not compatible with virt
Version-Release number of selected component (if applicable):
Steps to Reproduce:
This is tricky, since we currently can't force a virt provisioning.
Note that there are a few other bits of code with a similar problem:
* S/390 zpxe needs to be given ftp:// URLs, even if you want Anaconda to use nfs://
* beaker-provision needs either http:// or ftp:// to download the images and put them into /var/lib/tftpboot, even if you want to Anaconda to use nfs://
So there are some other possible solutions here which might work better with the custom distro support.
For example, what if installation grew another column, in addition to tree_url? The tree_url specifies the URL for Anaconda (which might be nfs://) but you can optionally supply a netboot_url which specifies how to fetch the images. The netboot_url could default to the same as the tree_url if the tree_url is http:// or ftp://. It would only need to be specified in cases where there is a mismatch between what Beaker needs to supply for netbooting vs. what the recipe wants Anaconda to use.
Or there is another possible solution. On installation we already have columns for kernel and initrd. Typically these are relative paths which are resolved from the tree_url but they can also be absolute URLs. So if you want to use nfs:// for the installation then you just need to give an absolute http:// or ftp:// URL for the kernel and initrd so that Beaker can fetch it properly.
I've tried to come up with a quick fix here:
but it turns out it's not good.
The problem is that over long run the installation.tree_url should become the authoritative source. The patch would go backwards and promote the distro_tree again to be the authoritative source.
We are not planning to support Openstack as part of Beaker anymore.
If you have any questions, please reach out to me.
Martin Styk <firstname.lastname@example.org>