Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document & parametrize certs::katello #166

Merged
merged 2 commits into from
Sep 5, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 9 additions & 11 deletions manifests/katello.pp
Original file line number Diff line number Diff line change
@@ -1,22 +1,20 @@
# Katello specific certs settings
# == Class: certs::katello
#
# This class builds an RPM containing the bootstrap for a candlepin consumer.
# This file is placed in $katello_www_pub_dir.
#
class certs::katello (
$hostname = $::certs::node_fqdn,
$deployment_url = undef,
$rhsm_port = 443,
$candlepin_cert_rpm_alias_filename = undef,
$rhsm_ca_dir = '/etc/rhsm/ca',
$candlepin_cert_rpm_alias_filename = 'katello-ca-consumer-latest.noarch.rpm',
$katello_www_pub_dir = '/var/www/html/pub',
$katello_server_ca_cert = $::certs::katello_server_ca_cert,
$server_ca_name = $::certs::server_ca_name,
$ca_cert = $::certs::ca_cert,
$server_ca = $::certs::server_ca,
) inherits certs {

$candlepin_cert_rpm_alias = $candlepin_cert_rpm_alias_filename ? {
undef => 'katello-ca-consumer-latest.noarch.rpm',
default => $candlepin_cert_rpm_alias_filename,
}

$katello_www_pub_dir = '/var/www/html/pub'
$rhsm_ca_dir = '/etc/rhsm/ca'
$katello_rhsm_setup_script = 'katello-rhsm-consumer'
$katello_rhsm_setup_script_location = "/usr/bin/${katello_rhsm_setup_script}"

Expand Down Expand Up @@ -58,7 +56,7 @@
files => ["${katello_rhsm_setup_script_location}:755=${katello_www_pub_dir}/${katello_rhsm_setup_script}"],
bootstrap_script => "/bin/bash ${katello_rhsm_setup_script_location}",
postun_script => 'test -f /etc/rhsm/rhsm.conf.kat-backup && command cp /etc/rhsm/rhsm.conf.kat-backup /etc/rhsm/rhsm.conf',
alias => $candlepin_cert_rpm_alias,
alias => $candlepin_cert_rpm_alias_filename,
subscribe => $server_ca,
}
}