Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Created attachment 1959934[details]
Satellite Content View Screenshot
Description of problem: The redhat.satellite.content_view_filter or content_view_filter_rule component incorrectly handles duplicate package names when the second entry lists a different architecture
Version-Release number of selected component (if applicable):
How reproducible:
Verified with this playbook:
- hosts: satellite
gather_facts: no
become: no
vars:
- rules:
- { name: "cairo", version: "1.15.12-6", arch: "x86_64" }
- { name: "cairo", version: "1.15.12-6", arch: "i686" }
tasks:
- name: Create Content Views
redhat.satellite.content_view:
server_url: "{{ server_url }}"
username: '{{ satellite_username }}'
password: '{{ satellite_password }}'
organization: "Default Organization"
name: RHEL8_Demo
auto_publish: false
state: present
- name: Create Content View Filters
redhat.satellite.content_view_filter:
server_url: "{{ server_url }}"
username: '{{ satellite_username }}'
password: '{{ satellite_password }}'
organization: "Default Organization"
name: "{{ item.name }}"
content_view: RHEL8_Demo
name: "Packages"
filter_state: present
filter_type: "rpm"
original_packages: True
inclusion: True
rule_name: "{{ item.name }}"
version: "{{ item.version }}"
architecture: "{{ item.arch }}"
loop: "{{ rules }}"
Steps to Reproduce:
1. Set up Satellite and sync the RHEL 8 BaseOS and AppStream repositories
2. Run the provided playbook, providing the necessary variables for the target Satellite server
3. Check the created content view filter. Instead of two entries for cairo showing different architectures and a specific package release, it shows a single entry where the architecture is the last item submitted to Satellite, and the package release is "All versions."
Actual results:
See screenshot
Expected results:
Two entries for the cario package, each with the specified package release and the specified package architecture.
Two things:
1. your playbook has "name" twice for the filter module, and by default the last one wins.
2. the way you use it right now it overwrites the x86_64 filter with the i686 one in the loop, as you pass the same name for the filter in both cases (either "packages" or after fixing 1/ "cairo").
Now, you will notice that there is no other way to pass multiple rules into one filter with the content_view_filter module.
This is why we created the content_view_filter_rule module, but even that has a bug with architecture handling, so let's fix that :)
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory (Important: Satellite 6.15.0 release), and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.
https://access.redhat.com/errata/RHSA-2024:2010
Created attachment 1959934 [details] Satellite Content View Screenshot Description of problem: The redhat.satellite.content_view_filter or content_view_filter_rule component incorrectly handles duplicate package names when the second entry lists a different architecture Version-Release number of selected component (if applicable): How reproducible: Verified with this playbook: - hosts: satellite gather_facts: no become: no vars: - rules: - { name: "cairo", version: "1.15.12-6", arch: "x86_64" } - { name: "cairo", version: "1.15.12-6", arch: "i686" } tasks: - name: Create Content Views redhat.satellite.content_view: server_url: "{{ server_url }}" username: '{{ satellite_username }}' password: '{{ satellite_password }}' organization: "Default Organization" name: RHEL8_Demo auto_publish: false state: present - name: Create Content View Filters redhat.satellite.content_view_filter: server_url: "{{ server_url }}" username: '{{ satellite_username }}' password: '{{ satellite_password }}' organization: "Default Organization" name: "{{ item.name }}" content_view: RHEL8_Demo name: "Packages" filter_state: present filter_type: "rpm" original_packages: True inclusion: True rule_name: "{{ item.name }}" version: "{{ item.version }}" architecture: "{{ item.arch }}" loop: "{{ rules }}" Steps to Reproduce: 1. Set up Satellite and sync the RHEL 8 BaseOS and AppStream repositories 2. Run the provided playbook, providing the necessary variables for the target Satellite server 3. Check the created content view filter. Instead of two entries for cairo showing different architectures and a specific package release, it shows a single entry where the architecture is the last item submitted to Satellite, and the package release is "All versions." Actual results: See screenshot Expected results: Two entries for the cario package, each with the specified package release and the specified package architecture.