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.
Bug 1873842 - Assigning openscap policy at host level generates the "/etc/foreman_scap_client/config.yaml" file with blank smart-proxy name in Satellite 6.8-Beta
Summary: Assigning openscap policy at host level generates the "/etc/foreman_scap_clie...
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: SCAP Plugin
Version: 6.8.0
Hardware: All
OS: Unspecified
unspecified
medium
Target Milestone: Unspecified
Assignee: satellite6-bugs
QA Contact: Jameer Pathan
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-08-30 14:46 UTC by Sayan Das
Modified: 2024-05-10 12:50 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-03-18 19:44:22 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 30743 0 Normal New Order of steps when assigning policy directly to host should not matter 2021-02-18 21:49:55 UTC

Description Sayan Das 2020-08-30 14:46:03 UTC
Description of problem:

If a host is not part of any hostgroup but I am assigning a scap policy at host level, then after the ansible role gets executed, the "/etc/foreman_scap_client/config.yaml" on the host has all the necessary information except the server name i.e. openscap capsule name.

~~
# Foreman proxy to which reports should be uploaded
:server: 
:port: 9090

~~


Version-Release number of selected component (if applicable):
satellite-6.8.0-0.7.beta.el7sat.noarch

How reproducible:
Always on a newly registered host without associating it with any hostgroup

Steps to Reproduce:
1. Register a host to satellite but don't associate any hostgroup.
2. Ensure that the host has openscap capsule selected and assign the "theforeman.foreman_scap_client" role for the host.
3. Assign a policy to that host using the Bulk Action from All Hosts page.
4. Run the "theforeman.foreman_scap_client" role on the host.
5. Check the "/etc/foreman_scap_client/config.yaml" file on the host.
6. Assign the same host to a hostgroup where same policy and scap capsule is selected and then re-run the same job. 
7. Check the "/etc/foreman_scap_client/config.yaml" file on the host.

Actual results:

1. At step 5, The entire content of the "/etc/foreman_scap_client/config.yaml" file is OK but the "server" parameter is missing the openscap capsule name.
~~
# Foreman proxy to which reports should be uploaded
:server: 
:port: 9090
~~

2. At Step 7, the content of "/etc/foreman_scap_client/config.yaml" file is complete now i.e. openscap capsule name is populated now in the config file along with port.
~~
# Foreman proxy to which reports should be uploaded
:server: satellite.example.com
:port: 9090

~~

Expected results:

At step 5 i.e. when the host is not assigned with hostgroup, the content of "/etc/foreman_scap_client/config.yaml" should contain the smart-proxy name as long as correct openscap capsule is assigned at host level.


Additional info:

I can reproduce it on Satellite 6.8 Beta for any new host registered without hostgroup.

Comment 3 Sayan Das 2020-08-31 07:53:14 UTC
*** Update ***

This issue is only reproducible at Host level, when Compliance policy is being associated first and Openscap capsule for the host is being selected next.

If I select the Openscap capsule first and the assign the compliance policy to the host, the issue will not occur.


Not sure why the sequence will matter, as long as the openscap capsule is selected  whether it's before or after assigning the policy ?

Comment 4 Ondřej Pražák 2020-08-31 10:50:34 UTC
Created redmine issue https://projects.theforeman.org/issues/30743 from this bug

Comment 9 Mike McCune 2022-01-28 22:30:40 UTC
Upon review of our valid but aging backlog the Satellite Team has concluded that this Bugzilla does not meet the criteria for a resolution in the near term, and are planning to close in a month. This message may be a repeat of a previous update and the bug is again being considered to be closed. If you have any concerns about this, please contact your Red Hat Account team. Thank you.

Comment 10 Mike McCune 2022-03-18 19:44:22 UTC
Thank you for your interest in Red Hat Satellite. We have evaluated this request, and while we recognize that it is a valid request, we do not expect this to be implemented in the product in the foreseeable future. This is due to other priorities for the product, and not a reflection on the request itself. We are therefore closing this out as WONTFIX. If you have any concerns about this feel free to contact your Red Hat Account Team. Thank you.

Comment 11 Lukáš Hellebrandt 2024-05-10 12:50:24 UTC
For the record, I can still reproduce this on stream snap 59.0 and the bug is not hard to hit at all.


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