Actions
Issue #770
closedWhen applying errata, pulp attempts to install packages to consumer that are not available
Start date:
Due date:
Estimated time:
Severity:
1. Low
Version:
2.6 Beta
Platform Release:
2.6.1
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Quarter:
Description
If a user attempts to apply an erratum that contains packages from various repos, Pulp will attempt to install the newest package available in that erratum. This is incorrect since the erratum may refer to packages that are unavailable to that consumer.
To reproduce on 2.6 0.9.rc:
- create and sync a rhel6 repo
- create and sync a rhel7 repo
- create a rhel6 consumer and bind it to the rhel6 repo
- run:
pulp-admin rpm consumer errata install run --consumer-id my-el6 --errata-id 'RHEA-2015:0141'
result:
Install task created with id [ bab4bb99-939e-4f67-86ec-f8ba2793f80d ]
This command may be exited via ctrl+c without affecting the request.
Refresh Repository Metadata
Refresh Repository Metadata
+12Downloading: None
Install Failed
0:tzdata-java-2015a-1.el7.noarch: No package(s) available to install
We should not be attempting to install the el7 package on the el6 system, since it's not in any repo that the el6 system is bound to.
Actions
770: Only apply packages in errata when they are actually available
Previously, if an erratum contained packages with the same name but different versions, Pulp would attempt to install the latest version of said package when applying an erratum to a system. This behavior is incorrect since an erratum might contain multiple packages across repos.
Instead, we need to filter out any packages that we do not have access to before applying the erratum.
re #770