Description of problem: I built a custom index. I point to it with --source Unfortunately, because there is already a machine with the same name in the public index, that machine is seen, and mine is not. I would expect: 1) That anything specified with --source take precedence *over* any built-ins. 2) There be an option to only show images from --source when desired. eg: --only-include-manual-sources (or something with a better name) Version-Release number of selected component (if applicable): $ virt-builder --version virt-builder 1.28.6 How reproducible: 100% Additional info: This feature is pretty important for anyone trying to have a custom index to build an image variant for something that already exists in stock repos.
(In reply to James (purpleidea) from comment #0) > 1) That anything specified with --source take precedence *over* any > built-ins. --source just adds new sources to the existing sources, with no special treatment. This means they are merged together the processed repositories, so any of the templates in the specified --source is used only whether (a) doesn't exist already (b) exist but its architecture does not exist (c) exist already also for its architecture, but its revision= is greater. The change to process --source options ahead of repositories is easy to do, although it won't change the result in case the template you are "overriding" get a revision bump; sent for review: https://www.redhat.com/archives/libguestfs/2015-February/msg00160.html
(In reply to Pino Toscano from comment #1) > (In reply to James (purpleidea) from comment #0) > > 1) That anything specified with --source take precedence *over* any > > built-ins. > > --source just adds new sources to the existing sources, with no special > treatment. This means they are merged together the processed repositories, > so any of the templates in the specified --source is used only whether (a) > doesn't exist already (b) exist but its architecture does not exist (c) > exist already also for its architecture, but its revision= is greater. > > The change to process --source options ahead of repositories is easy to do, > although it won't change the result in case the template you are > "overriding" get a revision bump; sent for review: > https://www.redhat.com/archives/libguestfs/2015-February/msg00160.html Cool... Would having an --only-source type option make sense or be useful to anyone besides me?
(In reply to James (purpleidea) from comment #0) > 2) There be an option to only show images from --source when desired. eg: > --only-include-manual-sources (or something with a better name) virt-builder uses XDG paths (the $XDG_CONFIG_DIRS envvar for system paths, and $XDG_CONFIG_HOME for user's one) as base for the repositories; if you don't want to use them, it should be enough to set them empty: env XDG_CONFIG_DIRS="" virt-builder ...
(In reply to Pino Toscano from comment #1) > (In reply to James (purpleidea) from comment #0) > > 1) That anything specified with --source take precedence *over* any > > built-ins. > > --source just adds new sources to the existing sources, with no special > treatment. This means they are merged together the processed repositories, > so any of the templates in the specified --source is used only whether (a) > doesn't exist already (b) exist but its architecture does not exist (c) > exist already also for its architecture, but its revision= is greater. > > The change to process --source options ahead of repositories is easy to do, > although it won't change the result in case the template you are > "overriding" get a revision bump; sent for review: > https://www.redhat.com/archives/libguestfs/2015-February/msg00160.html This is fixed with https://github.com/libguestfs/libguestfs/commit/17dabd57c78c021f17169fe69643a35c6c3b7ef9 which is in libguestfs >= 1.29.27.
Reading again the original bug report: (1) has been fixed one year ago (see comment #4) (2) is possible by setting the XDG_CONFIG_DIRS and XDG_CONFIG_HOME envvars (see comment #3, and the virt-builder man page) Hence, this bug report can be closed now -- feel free to reopen in case you think something has not been fixed yet.