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.

Bug 1578321

Summary: On "Edit" host page, Satellite webui shows the "Content Source" value inherited from the HostGroup instead of the one currently set to the host.
Product: Red Hat Satellite Reporter: Ashish Humbe <ahumbe>
Component: Host FormAssignee: Daniel Lobato Garcia <dlobatog>
Status: CLOSED DUPLICATE QA Contact: Katello QA List <katello-qa-list>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.3.1CC: gapatil, kgaikwad, mhulan, rabajaj, sgraessl, tbrisker
Target Milestone: UnspecifiedKeywords: Regression, Triaged
Target Release: Unused   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-07-19 11:37:29 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Ashish Humbe 2018-05-15 09:25:08 UTC
Description of problem:

When we try to edit the host from satellite webui which has a host group associated, the edit page shows the "Content Source" value inherited from HostGroup instead of the currently set value of the content source. 

- While we check the host details using Hammer command, we can see the currently set value of Content Source.

# hammer host info --name rhel7u4-1.example.com | egrep 'Content Source' -A2
    Content Source:        
        ID:   1
        Name: satellite.example.com

- While we try to Edit the Host from satellite webui it shows the value 

  A. As blank                 -  if the Content Source is not set or kept blank in the HostGroup associated with the Host.
  B. As "capsule.example.com" -  if the Content Source is set as "capsule.example.com" in the associated hostgroup. 



Version-Release number of selected component (if applicable):
Satellite v 6.3

How reproducible:
Always

Steps to Reproduce:

Scenario A:

1. Create a HostGroup or Nested HostGroup and keep the Content Source as blank. 
2. Associate the newly created host group to a host on the satellite webui and set the "Content Source" for the host as "satellite.example.com"
3. When we try to Edit the host, the satellite webui shows the "Content Source" value as blank instead of "satellite.example.com"


Scenario B:

1. Create a HostGroup or Nested HostGroup and set Content Source as "capsule.example.com". 
2. Associate the newly created host group to a host on the satellite webui and set the "Content Source" for the host as "satellite.example.com"
3. When you try to Edit the host the satellite webui shows the "Content Source" value as "capsule.example.com" instead of "satellite.example.com"

Actual results:
The "Edit" page for the host shows the Content Source value inherited from the HostGroup instead of the currently set value to the host.

Expected results:

1. The "Edit" page for the host should show the currently set value for the "Content Source" (if it is already set to the Host)

2. If the "Content Source" is not set for the Host then "Edit" page should not inherit the value from HostGroup. 

Additional info:

Comment 1 Ashish Humbe 2018-05-15 10:00:10 UTC
On Satellite v 6.2, on the Edit Host page, we can see the currently set value for the host.

Comment 4 Kavita 2018-05-30 15:48:06 UTC
Created redmine issue http://projects.theforeman.org/issues/23745 from this bug