-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
None
+++ This bug was initially created as a clone of Bug #2255546 +++
Description of problem:
When publishing a content view containing 1 module containing repository and 1 non-module containing repository, the non-module containing repository is created with all modules from the module containing repository.
Version-Release number of selected component (if applicable):
satellite-6.13.6
How reproducible:
Every time
Steps to Reproduce:
1. Create a content view containing 1 module and 1 non-module repository (IE: 'Red Hat Enterprise Linux 8 for x86_64 - AppStream RPMs 8' & 'Red Hat Ansible Engine 2 for RHEL 8 x86_64 RPMs'
2. Create a content-view filter for module streams with the following settings:
- Include: true
3. Add a rule to this CV filter to: - include all module streams
- original-module-streams: false
- Apply to all repositories in the CV: true
4. Publish a new version
5. Observe the package count for the non-module containing repository (IE: 'Red Hat Ansible Engine 2 for RHEL 8 x86_64 RPMs')
Actual results:
- hammer content-view version info --content-view '03676447-dup-test' --id 2 --include-applied-filters true
Id: 2
Name: 03676447-dup-test 1.0
Version: 1.0
Description:
Content View ID: 2
Content View Name: 03676447-dup-test
Content View Label: 03676447-dup-test
Lifecycle Environments:
1) Id: 1
Name: Library
Label: Library
Repositories:
1) Id: 29
Name: Red Hat Enterprise Linux 8 for x86_64 - AppStream RPMs 8
Label: Red_Hat_Enterprise_Linux_8_for_x86_64_-_AppStream_RPMs_8
2) Id: 30
Name: Red Hat Ansible Engine 2 for RHEL 8 x86_64 RPMs
Label: Red_Hat_Ansible_Engine_2_for_RHEL_8_x86_64_RPMs
Has Applied Filters: yes
Applied Filters:
1) Id: 1
Name: module stream lockdown
Type: modulemd
Inclusion: yes
Original packages: no
Original module streams: no
Rules:
1) Id: 1
Module stream Id: 2154
Content view filter Id: 1
2) Id: 2
Module stream Id: 771
Content view filter Id: 1
-snip-
749)Id: 749
Module stream Id: 23
Content view filter Id: 1
Dependency Solving: false
===========================================
[root@bombsat615 ~]# hammer repository info --id 30
Id: 30
Name: Red Hat Ansible Engine 2 for RHEL 8 x86_64 RPMs
Label: Red_Hat_Ansible_Engine_2_for_RHEL_8_x86_64_RPMs
Description:
Organization: Default Organization
Red Hat Repository: yes
Content Type: yum
Content Label: ansible-2-for-rhel-8-x86_64-rpms
Mirroring Policy: Complete Mirroring
Url: https://cdn.redhat.com/content/dist/layered/rhel8/x86_64/ansible/2/os
Publish Via HTTP: no
Published At: https://bombsat615.d.sysmgmt.cee.redhat.com/pulp/content/Default_Organization/content_views/03676447-dup-test/1.0/content/dist/layered/rhel8/x86_64/ansible/2/os/
Relative Path: Default_Organization/content_views/03676447-dup-test/1.0/content/dist/layered/rhel8/x86_64/ansible/2/os
Download Policy: on_demand
HTTP Proxy:
HTTP Proxy Policy: global_default_http_proxy
Product:
Id: 213
Name: Red Hat Ansible Engine
GPG Key:
Sync:
Status: Not Synced
Created: 2023/12/21 17:20:43
Updated: 2023/12/21 17:20:43
Content Counts:
Packages: 11183
Source RPMS: 0
Package Groups: 0
Errata: 32
Module Streams: 749
[root@bombsat615 ~]# hammer repository info --id 28
Id: 28
Name: Red Hat Ansible Engine 2 for RHEL 8 x86_64 RPMs
Label: Red_Hat_Ansible_Engine_2_for_RHEL_8_x86_64_RPMs
Description:
Organization: Default Organization
Red Hat Repository: yes
Content Type: yum
Content Label: ansible-2-for-rhel-8-x86_64-rpms
Mirroring Policy: Complete Mirroring
Url: https://cdn.redhat.com/content/dist/layered/rhel8/x86_64/ansible/2/os
Publish Via HTTP: no
Published At: https://bombsat615.d.sysmgmt.cee.redhat.com/pulp/content/Default_Organization/Library/content/dist/layered/rhel8/x86_64/ansible/2/os/
Relative Path: Default_Organization/Library/content/dist/layered/rhel8/x86_64/ansible/2/os
Download Policy: on_demand
HTTP Proxy:
HTTP Proxy Policy: global_default_http_proxy
Product:
Id: 213
Name: Red Hat Ansible Engine
GPG Key:
Sync:
Status: Success
Last Sync Date: about 1 hour
Created: 2023/12/21 17:20:43
Updated: 2023/12/21 17:20:43
Content Counts:
Packages: 58
Source RPMS: 0
Package Groups: 0
Errata: 32
Module Streams: 0
Expected results:
Module content should only be in repositories that contain module content after the publish.
Additional info:
— Additional comment from Taft Sanders on 2023-12-21 19:33:01 UTC —
A workaround to this issue is to update the CV filter for the module stream to refine the scope of the affected repositories to only the repository that contains module data. The below hammer command will change the affected repository for the rules in the CV filter:
- '7' is the Appstream root repository ID for this test satellite
[root@bombsat615 ~]# hammer content-view filter update --content-view '03676447-dup-test' --name 'module stream lockdown' --repository-ids 7 --organization-id 1
Filter updated.
//Steps to verify the new package count for version 2 of the CV:
[root@bombsat615 ~]# hammer content-view publish --name '03676447-dup-test' --organization-id 1
[..................................................................................................................................................................] [100%]
[root@bombsat615 ~]# hammer content-view version list --content-view '03676447-dup-test' --organization-id 1
--|---------------------|-------|-----------|----------------------
ID | NAME | VERSION | DESCRIPTION | LIFECYCLE ENVIRONMENTS
--|---------------------|-------|-----------|----------------------
3 | 03676447-dup-test 2.0 | 2.0 | | Library
2 | 03676447-dup-test 1.0 | 1.0 | |
--|---------------------|-------|-----------|----------------------
[root@bombsat615 ~]# hammer content-view version info --id 3 --fields Repositories
Repositories:
1) Id: 33
Name: Red Hat Enterprise Linux 8 for x86_64 - AppStream RPMs 8
Label: Red_Hat_Enterprise_Linux_8_for_x86_64_-_AppStream_RPMs_8
2) Id: 34
Name: Red Hat Ansible Engine 2 for RHEL 8 x86_64 RPMs
Label: Red_Hat_Ansible_Engine_2_for_RHEL_8_x86_64_RPMs
[root@bombsat615 ~]# for i in
{33,34}; do hammer repository info --id $i --fields "Content counts","Name"; done
Name: Red Hat Enterprise Linux 8 for x86_64 - AppStream RPMs 8
Content Counts:
Packages: 35090
Source RPMS: 0
Package Groups: 58
Errata: 3424
Module Streams: 749
Name: Red Hat Ansible Engine 2 for RHEL 8 x86_64 RPMs
Content Counts:
Packages: 58
Source RPMS: 0
Package Groups: 0
Errata: 32
Module Streams: 0