[Yum] Merge-able yum repos.d configuration?

Brian Mathis brian.mathis+yum at betteradmin.com
Tue Aug 20 21:09:44 UTC 2013


Has it been considered, or is there a way, to merge multiple files into a
single functional repository configuration?  The idea is to be able to
modify a repo configuration without editing the original file.  This would
be very helpful for plugins, such as priorities, where editing all repo
files can be tedious or not desired.  It would also improve usage on
installations using configuration management tools.

Example:
    /etc/yum.repos.d/example.repo:
        [example]
        name = Example Repo
        baseurl = http://127.0.0.1/repo/example



        enabled = 1

    /etc/yum.repos.d/merge.repo:
        [example]
        priority = 20

        [base-*]
        priority = 10

        [*]
        priority = 50

Yum would read both files and merge the config where the repo names match,
then act as if they are in the same file.  Wildcards could also be
supported to set defaults, for example.  Precedence could be handled by
simple rules, such as where the files are read in alphabetical order and
the last found setting is applied.

Has this been considered?  Is it possible to achieve this now?

I'm on CentOS 6.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.baseurl.org/pipermail/yum/attachments/20130820/83dfcc7e/attachment.html>


More information about the Yum mailing list