waveclaw / puppet-subscription_manager

Handle Client Registration to RedHat Satellite 6 or Katello
https://rhn.redhat.com
Other
6 stars 34 forks source link

Puppetrun takes very long if connection to RHN not possible #75

Closed mungo312 closed 5 years ago

mungo312 commented 5 years ago

We are using the module with katello. In our environment a direct connection to rhn is not possible. On the first puppetrun the evaluation of the rhn facts takes very long because subscription-manager tries to list all repos.

Maybe it would be quite clever to check if the system is registered before checking for the repos ?

waveclaw commented 5 years ago

The facts are straight dumb pulls from the subscription-manager commands. These facts do not care if the server is registered, just what the commands return. In the case of a server connected to RHN this will always be a huge list.

Checking for registration has a few very nasty edge cases. Since using a Katello server with unknown RHEL licenses and operating in a non-RHN, non-Katello mode are a supported scenario I do not intend to add any probing of registration.