[f21/master] Use first part of Product as repo name (#1128474)
Vratislav Podzimek
vpodzime at redhat.com
Wed Sep 3 10:57:06 UTC 2014
On Tue, 2014-09-02 at 17:15 -0700, Brian C. Lane wrote:
> Anaconda uses the Product from .buildstamp as the name of the repo to
> use for mirror installations. This has to match an entry in
> /etc/anaconda.repos.d/
>
> We share the repositories between the various Products so we should only
> use the first element (splitting on '-') as the name of the repo.
> ---
> pyanaconda/packaging/__init__.py | 2 +-
> pyanaconda/packaging/yumpayload.py | 1 +
> 2 files changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/pyanaconda/packaging/__init__.py b/pyanaconda/packaging/__init__.py
> index c368e0d..b8f13e2 100644
> --- a/pyanaconda/packaging/__init__.py
> +++ b/pyanaconda/packaging/__init__.py
> @@ -677,7 +677,7 @@ class ArchivePayload(ImagePayload):
> class PackagePayload(Payload):
> """ A PackagePayload installs a set of packages onto the target system. """
>
> - DEFAULT_REPOS = [productName.lower(), "rawhide"]
> + DEFAULT_REPOS = [productName.split('-')[0].lower(), "rawhide"]
>
> def __init__(self, data):
> if self.__class__ is PackagePayload:
> diff --git a/pyanaconda/packaging/yumpayload.py b/pyanaconda/packaging/yumpayload.py
> index 6dca7f6..3c1994e 100644
> --- a/pyanaconda/packaging/yumpayload.py
> +++ b/pyanaconda/packaging/yumpayload.py
> @@ -439,6 +439,7 @@ reposdir=%s
> else:
> # didn't find any base repo set and enabled
> with self._base_repo_lock:
> + log.debug("No base_repo found in %s", BASE_REPO_NAMES)
> self._base_repo = None
>
> @property
ACK.
--
Vratislav Podzimek
Anaconda Rider | Red Hat, Inc. | Brno - Czech Republic
More information about the anaconda-patches
mailing list