Skip to content

Commit

Permalink
Add defaults and make server_timeout and inotify configurable (fixes v…
Browse files Browse the repository at this point in the history
…oxpupuli#85)

Add defaults from subscription-manager 1.21.10
  • Loading branch information
kallies committed Oct 25, 2019
1 parent ee78ef0 commit f0d9048
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 1 deletion.
5 changes: 5 additions & 0 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@
# @param baseurl Base URL for rhsm, default provided
# @param package_ensure Whether to install subscription-manager, directly passed to the `ensure` param of the package.
# @param enabled_repo_ids A listing of the Repo IDs to provide to the subscription-manager repo --enable command.
# @param server_timeout HTTP timeout in seconds
# @param inotify 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.
#
# @example
# include rhsm
Expand Down Expand Up @@ -70,6 +73,8 @@
Integer[0,1] $full_refresh_on_yum = 0,
String[1] $package_ensure = 'installed',
Array[String[1]] $enabled_repo_ids = [],
Integer[0,1] $inotify = 1,
Integer[0] $server_timeout = 180,
){

if ($rh_user == undef and $rh_password == undef) and ($org == undef and $activationkey == undef) {
Expand Down
17 changes: 16 additions & 1 deletion templates/rhsm.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,15 @@ proxy_password = <%= @proxy_password %>
# host/domain suffix blacklist for proxy, if needed
no_proxy =

server_timeout = <%= @server_timeout %>

[rhsm]
# Content base URL:
baseurl= <%= @baseurl %>

# Repository metadata GPG key URL:
repomd_gpg_url =

# Server CA certificate location:
ca_cert_dir = <%= @ca_cert_dir %>

Expand Down Expand Up @@ -64,6 +69,17 @@ pluginDir = /usr/share/rhsm-plugins
# The directory to search for plugin configuration files
pluginConfDir = /etc/rhsm/pluginconf.d

# Manage automatic enabling of yum/dnf plugins (product-id, subscription-manager)
auto_enable_yum_plugins = 1

# Inotify is used for monitoring changes in directories with certificates.
# Currently only the /etc/pki/consumer directory is monitored by the
# rhsm.service. When this directory is mounted using a network file system
# without inotify notification support (e.g. NFS), then disabling inotify
# is strongly recommended. When inotify is disabled, periodical directory
# polling is used instead.
inotify = <%= @inotify %>

[rhsmcertd]
# Interval to run cert check (in minutes):
certCheckInterval = 240
Expand All @@ -80,4 +96,3 @@ default_log_level = INFO
# rhsm.connection = DEBUG
# rhsm-app = DEBUG
# rhsm-app.rhsmd = DEBUG

0 comments on commit f0d9048

Please sign in to comment.