rhsm

Register with the RedHat Subscription Management

196,337 downloads

3,774 latest version

4.7 quality score

We run a couple of automated
scans to help you access a
module's quality. Each module is
given a score based on how well
the author has formatted their
code and documentation and
modules are also checked for
malware using VirusTotal.

Please note, the information below
is for guidance only and neither of
these methods should be considered
an endorsement by Puppet.

Version information

  • 5.3.0 (latest)
  • 5.2.0
  • 5.1.0
  • 5.0.0
  • 4.1.0
  • 4.0.0
  • 3.2.0
  • 3.1.0
  • 3.0.0
  • 2.1.1
  • 2.1.0
  • 2.0.0
  • 1.1.0
  • 1.0.0
  • 0.3.0
released May 25th 2024
This version is compatible with:
  • Puppet Enterprise 2025.3.x, 2025.2.x, 2025.1.x, 2023.8.x, 2023.7.x, 2023.6.x, 2023.5.x, 2023.4.x, 2023.3.x, 2023.2.x, 2023.1.x, 2023.0.x, 2021.7.x, 2021.6.x, 2021.5.x, 2021.4.x, 2021.3.x, 2021.2.x, 2021.1.x, 2021.0.x
  • Puppet >= 7.0.0 < 9.0.0

Start using this module

  • r10k or Code Manager
  • Bolt
  • Manual installation
  • Direct download

Add this module to your Puppetfile:

mod 'puppet-rhsm', '5.3.0'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add puppet-rhsm
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install puppet-rhsm --version 5.3.0

Direct download is not typically how you would use a Puppet module to manage your infrastructure, but you may want to download the module in order to inspect the code.

Download

Documentation

puppet/rhsm — version 5.3.0 May 25th 2024

Reference

Table of Contents

Classes

  • rhsm: Subscribe the node to RHSM

Resource types

Classes

rhsm

rhsm

Subscribe the node to RHSM

Copyright 2014 Ger Apeldoorn, unless otherwise noted.

Examples

include rhsm
# Hierafile:
---
rhsm::rh_user: myuser
rhsm::rh_password: mypassword

Parameters

The following parameters are available in the rhsm class:

rh_user

Data type: Optional[String[1]]

User for the Customer Portal. You need to specify either (rh_user and rh_password) or (org and activationkey)

Default value: undef

rh_password

Data type: Optional[String[1]]

Password for the rh_user account

Default value: undef

org

Data type: Optional[String[1]]

Organization to use

Default value: undef

activationkey

Data type: Optional[String[1]]

Activationkey to use

Default value: undef

servername

Data type: Stdlib::Fqdn

Servername, default provided Used directly in rhsm.conf template

Default value: 'subscription.rhsm.redhat.com'

serverprefix

Data type: Stdlib::Absolutepath

server.prefix to use Used directly in rhsm.conf template /rhsm for Satellite 6 /subscription for RHSM

Default value: '/subscription'

serverport

Data type: Stdlib::Port

server.port to use Used directly in rhsm.conf template

Default value: 443

ca_cert_dir

Data type: Stdlib::Absolutepath

Server CA certificate location

Default value: '/etc/rhsm/ca/'

repo_ca_cert_filename

Data type: String[1]

File containting the CA cert to use when generating yum repo configs katello-server-ca.pem for Satellite 6 redhat-uep.pem for RHSM

Default value: 'redhat-uep.pem'

repo_ca_cert_source

Data type: Optional[String[1]]

URI, if set the content is used for CA file resource ${ca_cert_dir}/${repo_ca_cert_filename} Possible values are puppet:, file: and http:

Default value: undef

manage_repos

Data type: Integer[0,1]

1 if subscription manager should manage yum repos file or 0 if the subscription is only used for tracking purposes

Default value: 1

full_refresh_on_yum

Data type: Integer[0,1]

rhsm.full_refresh_on_yum Used directly in rhsm.conf template 1 for Satellite 6 0 for RHSM

Default value: 0

proxy_hostname

Data type: Optional[Stdlib::Fqdn]

Proxy hostname

Default value: undef

proxy_scheme

Data type: Enum['http', 'https']

Proxy scheme

Default value: 'http'

proxy_port

Data type: Optional[Stdlib::Port]

Proxy port

Default value: undef

proxy_user

Data type: Optional[String[1]]

Proxy user

Default value: undef

proxy_password

Data type: Optional[String[1]]

Proxy password

Default value: undef

no_proxy

Data type: Optional[String[1]]

no_proxy definition

Default value: undef

baseurl

Data type: Stdlib::Httpurl

Base URL for rhsm, default provided

Default value: 'https://cdn.redhat.com'

package_ensure

Data type: String[1]

Whether to install subscription-manager, directly passed to the ensure param of the package.

Default value: 'installed'

enabled_subscription_ids

Data type: Array[String[1]]

A listing of subscription IDs to provide to the subscription-manager attach --pool command.

Default value: []

enabled_repo_ids

Data type: Array[String[1]]

A listing of the Repo IDs to provide to the subscription-manager repo --enable command.

Default value: []

server_timeout

Data type: Integer[0]

HTTP timeout in seconds

Default value: 180

inotify

Data type: Integer[0,1]

Inotify is used for monitoring changes in directories with certificates. When this directory is mounted using a network file system without inotify notification support (e.g. NFS), then disabling inotify is strongly recommended.

Default value: 1

process_timeout

Data type: Integer[0]

The time in seconds we will allow the rhsmd cron job to run before terminating the process.

Default value: 300

manage_repo_filename

Data type: Boolean

Should puppet try to manage the repo file subscription-manager uses?

Default value: true

repo_filename

Data type: Stdlib::Absolutepath

The name of the repo file subscription-manager uses.

Default value: '/etc/yum.repos.d/redhat.repo'

plugin_settings

Data type: Hash

Hash of {section => {key => value } } for the yum/dnf plugin.

Default value: { 'main' => { 'enabled' => 1 } }

package_profile_on_trans

Data type: Integer[0,1]

Run the package profile on each yum/dnf transaction

Default value: 0

Resource types

rh_repo

Manage Red Hat subscriptions

Properties

The following properties are available in the rh_repo type.

ensure

Valid values: present, enabled, absent, disabled

Aliases: "enabled"=>"present", "disabled"=>"absent"

The basic property that the resource should be in.

Parameters

The following parameters are available in the rh_repo type.

name

namevar

provider

The specific backend to use for this rh_repo resource. You will seldom need to specify this --- Puppet will usually discover the appropriate provider for your platform.

rh_subscription

Manage Red Hat subscriptions

Properties

The following properties are available in the rh_subscription type.

ensure

Valid values: present, absent

The basic property that the resource should be in.

Default value: present

Parameters

The following parameters are available in the rh_subscription type.

name

namevar

provider

The specific backend to use for this rh_subscription resource. You will seldom need to specify this --- Puppet will usually discover the appropriate provider for your platform.

serial