Bug 2103746

Summary: Unable to disable debian plugin in Satellite 6
Product: Red Hat Satellite Reporter: Jessica Richards <jrichards2>
Component: Foreman MaintainAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED NOTABUG QA Contact: Satellite QE Team <sat-qe-bz-list>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.9.0CC: apatel, ehelms, kgaikwad
Target Milestone: UnspecifiedKeywords: Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-07-28 13:31:44 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 Jessica Richards 2022-07-04 17:14:52 UTC
Description of problem:

The customer is able to use a custom answers file to forcefully enable the debian plugin setting for Satellite 6.  The plugin doesn't actually enable, because the packages aren't available, but the _setting_ can be forced this way.

However, whenever the satellite-installer or foreman-maintain tools run afterwards, they invariably fail (exit code 6).  This includes attempts to _disable_ the debian plugin using this command:

# satellite-installer --foreman-proxy-content-enable-deb false


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

Satellite 6.9


How reproducible:

unclear; we have one example so far


Steps to Reproduce:
1.  create a custom answer file in /etc/foreman-installer/scenarios.d/ with this option in the "katello:" section:

:enable_deb: true

2.  run "foreman-maintain packages update" to patch the server; it will fail

3.  run "satellite-installer --foreman-proxy-content-enable-deb false"; it will fail

Actual results:

- disabling the debian plugin is not possible after forcibly enabling it through a custom answer file


Expected results:

- since red hat satellite doesn't support the debian plugin, we should always be able to turn it off


Additional info:


The logs suggest that the satellite-installer command tries to install the debian-related pulp packages even when we're just trying to disable the setting.  This prevents the Satellite server from being patched, eventually leaving it in an insecure state.

Comment 1 Eric Helms 2022-07-21 02:53:17 UTC
Satellite does not support creating custom answer files and this practice can lead the Satellite to end up in an inconsistent state. 

As for the failure seen when attempting to configure " --foreman-proxy-content-enable-deb false", please include the output of the failure so that we may assess if this is something we will address on future versions of Satellite.

Comment 4 Jessica Richards 2022-07-26 00:59:03 UTC
I was able to help my Satellite 6.9 customer work around this issue by following these steps:

# cp /usr/share/foreman-installer/modules/pulp/manifests/install.pp /usr/share/foreman-installer/modules/pulp/manifests/install.pp.bak

# vi /usr/share/foreman-installer/modules/pulp/manifests/install.pp

Then we commented out these lines:

  if $pulp::enable_deb {
    package { ['pulp-deb-plugins']: ensure => $pulp::version, }
  }

So that they looked like these lines:

#  if $pulp::enable_deb {
#    package { ['pulp-deb-plugins']: ensure => $pulp::version, }
#  }

Then this command succeeded:

# satellite-installer --foreman-proxy-content-enable-deb false

Comment 5 Eric Helms 2023-07-28 13:31:44 UTC
Since this was done via a method that we do not support, and the customer issue has been resolved I am opting to close it.