When I build a repository: is there a way to use a mirrorlist as one would find in the default CentOS-Base.repo?
for instance: I would like my foreman/katello server to be able to pull packages down from a range of repositories rather than having to select just one.
At the moment I am upgrading to foreman 3.5, but I am asking as this is the time to experiment.
As you can see, the command does accept both --mirrorlist and --metalink as parameters, but the template has no way of providing them.
It iterates over the various medium providers, which implement the interface. Right now there’s no good way of providing that additional data, so that would be a feature request.
In the short term you can close the template and hardcode it. Not pretty, but it works.
I cannot say how or when this became supported but empirically now in 2024 running Foreman version 3.10.0 I am able to supply a mirror list URL in the ‘Sync Settings’ > ‘Upstream URL’ field of the Foreman repository settings page and it does work to automatically select the mirror with the best network connectivity and sync. Understandably the variable substitutions like ‘$releasever’ often used in a yum .repo file do not work.
As an example I’m using the following URLs in my Foreman repo config: