CentOS mirror installation media, which currently ships with Foreman, is set to
http://mirror.centos.org/centos/$major/os/$arch. This will not work for CentOS 8 and most likely for next versions as structure of the directories changed due to modularization. Therefore we need to reflect this because the overall goal is that CentOS provisioning should work out of box, even when Katello is not used (which handles this in its own way).
So for Foreman core, I propose one of the following changes:
Add some kind of heuristic into RedHat family operating system and if the version is higher than 8, then Foreman would rewrite the URL from
$major/BaseOS/$arch/kickstart. This is more user friendly to new users, however if you ask me I would prefer cleaner approach:
Add new installation media named “CentOS 8 mirror” with URL set to
http://mirror.centos.org/centos/$major/BaseOS/$arch/kickstart. There is a risk that users will not match OS versions and installation media correctly leading to 404 errors.
As I said, I prefer (2) and we can probably rename the old one too, so we would end up with something more obvious:
- CentOS mirror (7.x)
- CentOS mirror (8.x)
This convention should be pretty clear for 90% of the users of 7 and 8 versions, however there might be still some doubt for those who still use 6 or 5. But I think it’s fair since this should not be majority and anything like “CentOS legacy mirror” would be probably too confusing for users of 7.x series.
What you think?
I will then go ahead and rebase my initial PR to a simple installation mirror addition (and rename) since everything else works perfectly. No ther changes in Foreman core are needed and Katello-managed repositories should also work automatically with 8.0 due to the template change (additional_repos) in the 2.1 version.