add control for puppetdb.conf - https://gitlab.confdroid.com/internal/confdroid_management/-/issues/284
This commit is contained in:
@@ -30,5 +30,17 @@ class puppet_cd::main::files (
|
||||
content => template($pt_puppet_conf_erb),
|
||||
notify => Service[$pt_agent_service,$pt_server_service],
|
||||
}
|
||||
|
||||
if $pt_use_puppetdb == true {
|
||||
file { $pt_puppetdb_conf_file:
|
||||
ensure => file,
|
||||
path => $pt_puppetdb_conf_file,
|
||||
owner => 'root',
|
||||
group => 'root',
|
||||
mode => '0644',
|
||||
content => template($pt_puppetdb_conf_erb),
|
||||
notify => Service[$pt_agent_service,$pt_server_service],
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,8 +3,10 @@
|
||||
# Author: Arne Teuke (arne_teuke@confdroid)
|
||||
# @summary Class manages parameters for the puppet_cd module.
|
||||
# @param [Boolean] pt_manage_fw whether to manage firewall settings
|
||||
# @param [Boolean] pt_use_puppetdb whether to use puppetdb
|
||||
# @param [String] pt_pm_fqdn the fqdn for the puppetmaster and master
|
||||
# settings are applied. any other fqdn # will be considered a puppet agent.
|
||||
# settings are applied. any other fqdn # will be considered a puppet agent.
|
||||
# @param [String] pt_db_fqdn the fqdn for the puppetdb node.
|
||||
# @param [String] pt_pkg_ensure valid: "present", "latest", "v1.2.3"
|
||||
# @param [String] pt_agent_pkg the packages for agents to install
|
||||
# @param [String] pt_server_pkg the server packages to install
|
||||
@@ -50,11 +52,14 @@
|
||||
# @param [Array] pt_r10k_webhook_pkg the packages for the r10k webhook
|
||||
# @param [Boolean] pt_manage_user whether to manage the puppet user
|
||||
# @param [String] pt_r10k_webhook_port the port for the webhook listener
|
||||
# @param [String] pt_ssl_port the port for the puppetdb ssl port
|
||||
###############################################################################
|
||||
class puppet_cd::params (
|
||||
|
||||
Boolean $pt_manage_fw = true,
|
||||
String $pt_pm_fqdn = 'puppetmaster.example.net',
|
||||
String $pt_db_fqdn = 'puppetdb.example.net',
|
||||
Boolean $pt_use_puppetdb = false,
|
||||
|
||||
# installation
|
||||
String $pt_pkg_ensure = 'latest',
|
||||
@@ -101,6 +106,9 @@ class puppet_cd::params (
|
||||
String $pt_parser = 'current',
|
||||
Boolean $pt_cert_revocation = true,
|
||||
|
||||
# puppetdb
|
||||
String $pt_ssl_port = '8081',
|
||||
|
||||
# r10k
|
||||
Boolean $pt_use_r10k = false,
|
||||
Boolean $pt_use_r10k_webhook = false,
|
||||
@@ -137,8 +145,9 @@ class puppet_cd::params (
|
||||
## puppet
|
||||
$pt_puppet_conf_file = "${pt_puppetdir}/puppet.conf"
|
||||
$pt_puppet_conf_erb = 'puppet_cd/puppet.conf.erb'
|
||||
$pt_agent_conf_erb = 'puppet_cd/agent.conf.erb'
|
||||
$pt_hiera_config = "${pt_puppetdir}/hiera.yaml"
|
||||
$pt_puppetdb_conf_file = "${pt_puppetdir}/puppetdb.conf"
|
||||
$pt_puppetdb_conf_erb = 'puppet_cd/puppetdb/puppetdb.conf.erb'
|
||||
|
||||
## r10k
|
||||
$pt_r10k_file = "${pt_r10k_dir}/r10k.yaml"
|
||||
|
||||
Reference in New Issue
Block a user