Bug 2211328 - When simple content access is enabled, "--content-access-mode-all true" parameter should be passed to list the product content associated with the activation key [NEEDINFO]
Summary: When simple content access is enabled, "--content-access-mode-all true" para...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Activation Keys
Version: 6.11.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: Unspecified
Assignee: Aneta Šteflová Petrová
QA Contact: Satellite QE Team
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-05-31 06:31 UTC by Satyajit Das
Modified: 2023-06-26 14:51 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-06-26 14:51:29 UTC
Target Upstream Version:
Embargoed:
mdolezel: needinfo? (bangelic)


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker SAT-17986 0 None None None 2023-05-31 06:34:38 UTC

Description Satyajit Das 2023-05-31 06:31:50 UTC
Document URL: 

https://access.redhat.com/documentation/en-us/red_hat_satellite/6.11/html-single/managing_content/index#Managing_Activation_Keys_content-management


Section Number and Name: 

In the CLI procedure to create an activation key, using the hammer command

5. List the product content associated with the activation key:

Describe the issue: 

Entitlement-based Subscription Management is deprecated and it is recommended to use Simple Content Access, however, the command mentioned in the doc returns nothing if SCA is enabled in the Satellite.

Steps suggested in the doc:-

4. Attach the Red Hat Enterprise Linux subscription UUID to the activation key:

# hammer activation-key add-subscription \
--name "My_Activation_Key" \
--subscription-id My_Subscription_ID \
--organization "My_Organization"
5. List the product content associated with the activation key:

# hammer activation-key product-content \
--name "My_Activation_Key" \
--organization "My_Organization"

For ex.  If SCA is enabled in the satellite it returns nothing.

# hammer activation-key product-content --name Test --organization-id 1
---|------|------|-----|---------|-------|------------------|---------
ID | NAME | TYPE | URL | GPG KEY | LABEL | DEFAULT ENABLED? | OVERRIDE
---|------|------|-----|---------|-------|------------------|---------


Suggestions for improvement: 
After point 5, we should add a new point on how to list the product content associated with the activation key, if SCA is enabled.


If SCA is enabled in the satellite, to list product content using the hammer "--content-access-mode-all true" parameter should be passed.

For ex.  

# hammer activation-key product-content  --content-access-mode-all true  --name Test --organization-id 1
------|-----------------------------------------------------------------------|---------------------------------------------|------------------|---------
ID    | NAME                                                                  | LABEL                                       | DEFAULT ENABLED? | OVERRIDE
------|-----------------------------------------------------------------------|---------------------------------------------|------------------|---------
10742 | CentOS                                                                | RedHat_CentOS_CentOS                        | yes              |         
8134  | Centos 8 PowerTools                                                   | RedHat_EPEL-03138983_Centos_8_PowerTools    | yes              |         
10743 | Convert2RHEL                                                          | RedHat_CentOS_Convert2RHEL                  | yes              |         
7807  | epel-7                                                                | RedHat_EPEL-03138983_epel-7                 | yes              |         
7808  | epel-8                                                                | RedHat_EPEL-03138983_epel-8                 | yes              |         
10772 | jfrog                                                                 | RedHat_CentOS_jfrog                         | yes              |         
10739 | nagios-8                                                              | RedHat_ak-Reg_To_Crash1234444_nagios-8      | yes              |         
10740 | nagiosxi-deps                                                         | RedHat_ak-Reg_To_Crash1234444_nagiosxi-deps | yes              |         
5638  | Red Hat Ansible Engine 2.9 for RHEL 8 x86_64 (RPMs)                   | ansible-2.9-for-rhel-8-x86_64-rpms          | no               |         
5622  | Red Hat Ansible Engine 2.9 RPMs for Red Hat Enterprise Linux 7 Server | rhel-7-server-ansible-2.9-rpms              | no               |         
2590  | Red Hat Enterprise Linux 7 Server (Debug RPMs)                        | rhel-7-server-debug-rpms                    | no               |         
2588  | Red Hat Enterprise Linux 7 Server (Kickstart)                         | rhel-7-server-kickstart                     | no               |         
2587  | Red Hat Enterprise Linux 7 Server (RPMs)                              | rhel-7-server-rpms                          | yes              |         
335   | Red Hat Enterprise Linux 8 for x86_64 - AppStream (Kickstart)         | rhel-8-for-x86_64-appstream-kickstart       | no               |         
330   | Red Hat Enterprise Linux 8 for x86_64 - AppStream (RPMs)              | rhel-8-for-x86_64-appstream-rpms            | yes              |         
358   | Red Hat Enterprise Linux 8 for x86_64 - BaseOS (Kickstart)            | rhel-8-for-x86_64-baseos-kickstart          | no               |         
365   | Red Hat Enterprise Linux 8 for x86_64 - BaseOS (RPMs)                 | rhel-8-for-x86_64-baseos-rpms               | yes              |         
4924  | Red Hat Enterprise Linux 8 for x86_64 - High Availability (RPMs)      | rhel-8-for-x86_64-highavailability-rpms     | no               |         
7011  | Red Hat Enterprise Linux 9 for x86_64 - AppStream (Kickstart)         | rhel-9-for-x86_64-appstream-kickstart       | no               |         
7010  | Red Hat Enterprise Linux 9 for x86_64 - AppStream (RPMs)              | rhel-9-for-x86_64-appstream-rpms            | yes              |         
------|-----------------------------------------------------------------------|---------------------------------------------|------------------|---------


Additional information: 

Update the steps in the doc for all Satellite versions starting from 6.11 till the latest.

Comment 1 Marie Hornickova 2023-05-31 11:47:18 UTC
Hello Satyajit,
Many thanks for reporting this suggestion for improvement.
The BZ will go through proper team triage,and relevant updates about the progress on the implementation  will be shared in this ticket.
Thank you!

Comment 2 Aneta Šteflová Petrová 2023-06-22 12:55:31 UTC
PR submitted for review: https://github.com/theforeman/foreman-documentation/pull/2253


Note You need to log in before you can comment on or make changes to this bug.