taking a default puppet_vardir
This commit is contained in:
@@ -12,6 +12,10 @@ class puppet::common ($ensure = 'present') {
|
||||
|
||||
$facts_d = '/etc/facter/facts.d'
|
||||
File['/etc/facter'] -> File[$facts_d]
|
||||
$pv_dir = $::puppet_vardir ? {
|
||||
'' => '/var/lib/puppet',
|
||||
default => $::puppet_vardir
|
||||
}
|
||||
|
||||
file {
|
||||
[
|
||||
@@ -22,10 +26,11 @@ class puppet::common ($ensure = 'present') {
|
||||
owner => 'root',
|
||||
group => 'root';
|
||||
|
||||
"${::puppet_vardir}/exported":
|
||||
"${pv_dir}/exported":
|
||||
ensure => $ens_dir;
|
||||
}
|
||||
$factpath = "${::puppet_vardir}/lib/facter"
|
||||
$factpath = "${pv_dir}/lib/facter"
|
||||
|
||||
# add facter variable to custom facts.
|
||||
file { '/etc/profile.d/puppet.sh': content => "export FACTERLIB=\"${factpath}\"\n",
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user