environments
This commit is contained in:
@@ -6,7 +6,9 @@ class puppet::agent (
|
||||
$run_hour = '*/1',
|
||||
$run_minute = '10',
|
||||
$run_if_ipmatch = undef,
|
||||
$maxsleep = '3200') {
|
||||
$maxsleep = '3200',
|
||||
$puppet_master = undef,
|
||||
$environment = gsub($::domain,'.lan', '')) {
|
||||
case $::kernel {
|
||||
'Linux' : {
|
||||
$puppetpkgs = ['puppet', 'puppet-common']
|
||||
@@ -79,5 +81,16 @@ class puppet::agent (
|
||||
setting => 'splay',
|
||||
value => $maxsleep;
|
||||
}
|
||||
ini_setting { 'puppet-agent-env':
|
||||
setting => 'environment',
|
||||
value => $environment;
|
||||
}
|
||||
|
||||
if $puppet_master != undef {
|
||||
ini_setting { 'puppet-agnt-master':
|
||||
setting => 'server',
|
||||
value => $puppet_master,
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -36,3 +36,4 @@ splay=true
|
||||
report=true
|
||||
server=<%= scope.lookupvar("puppetmaster_server") %>
|
||||
configtimeout=720
|
||||
environment=<% @domain.gsub('.lan','')
|
||||
|
||||
Reference in New Issue
Block a user