Project

General

Profile

Actions

Feature #31103

open

[RFE] Allow installing katello-(agent,host-tools,host-tools-tracer) based on the declarations via host\hostgroup parameters during system build

Added by Sayan Das over 3 years ago. Updated almost 3 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Templates
Target version:
-
Difficulty:
easy
Triaged:
No
Fixed in Releases:
Found in Releases:

Description

The https://projects.theforeman.org/issues/30738 is providing a way to skip the katello-agent installation via host-paramateres but still,

  • "redhat_install_agent"\redhat_install_host_tools"\"redhat_install_host_tracer_tools" should not be dependant on activation_key
  • User should be able to individually set those parameters as true or false at host or host group level, to decide which package to install and which not to.

Suggesting implementation with a small code modification inside "redhat_register.erb" i.e. to move those parameter declarations out of the if-else loop

~~~
<% if registration_type == 'subscription_manager' >
<

atomic = @host.operatingsystem.respond_to?(:atomic) ? @host.operatingsystem.atomic? : host_param_true?('atomic')

if host_param('kt_activation_keys')
subscription_manager_certpkg_url = subscription_manager_configuration_url(@host)
subscription_manager_atomic_url = subscription_manager_configuration_url(@host, false)
subscription_manager_org = @host.rhsm_organization_label
activation_key = host_param('kt_activation_keys')
else
subscription_manager_certpkg_url = host_param('subscription_manager_certpkg_url')
subscription_manager_atomic_url = host_param('subscription_manager_atomic_url')
subscription_manager_org = host_param('subscription_manager_org')
activation_key = host_param('activation_key')
end
redhat_install_agent = host_param_true?('redhat_install_agent')
redhat_install_host_tools = host_param_true?('redhat_install_host_tools')
redhat_install_host_tracer_tools = host_param_true?('redhat_install_host_tracer_tools')
%>
~~~

This change is actually much more efficient as if someone sets "redhat_install_host_tools" to "true" at the host or host group level, only then katello-host-tools will be installed, or else none of those three packages will be installed.

Actions #1

Updated by The Foreman Bot about 3 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/8376 added
Actions #2

Updated by The Foreman Bot almost 3 years ago

  • Status changed from Ready For Testing to New
  • Pull request deleted (https://github.com/theforeman/foreman/pull/8376)
Actions

Also available in: Atom PDF