Skip to content

Commit 2093aa3

Browse files
Merge pull request #90 from kronos-pbrideau/master
Add options to puppet config
2 parents 2cdd4de + 0217618 commit 2093aa3

File tree

1 file changed

+63
-9
lines changed

1 file changed

+63
-9
lines changed

manifests/agent.pp

Lines changed: 63 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -42,30 +42,40 @@
4242
# }
4343
#
4444
class puppet::agent(
45-
$puppet_server = $::puppet::params::puppet_server,
46-
$puppet_server_port = $::puppet::params::puppet_server_port,
4745
$puppet_agent_service = $::puppet::params::puppet_agent_service,
4846
$puppet_agent_package = $::puppet::params::puppet_agent_package,
4947
$version = 'present',
5048
$puppet_run_style = 'service',
51-
$puppet_run_interval = 30,
5249
$puppet_run_command = '/usr/bin/puppet agent --no-daemonize --onetime --logdest syslog > /dev/null 2>&1',
5350
$user_id = undef,
5451
$group_id = undef,
55-
$splay = false,
56-
$environment = 'production',
57-
$report = true,
58-
$pluginsync = true,
59-
$use_srv_records = false,
52+
53+
#[main]
54+
$templatedir = undef,
55+
$syslogfacility = undef,
56+
$priority = undef,
57+
58+
#[agent]
6059
$srv_domain = undef,
6160
$ordering = undef,
62-
$templatedir = undef,
6361
$trusted_node_data = undef,
62+
$environment = 'production',
63+
$puppet_server = $::puppet::params::puppet_server,
64+
$use_srv_records = false,
65+
$puppet_run_interval = 30,
66+
$splay = false,
67+
$puppet_server_port = $::puppet::params::puppet_server_port,
68+
$report = true,
69+
$pluginsync = true,
6470
$listen = false,
6571
$reportserver = '$server',
6672
$digest_algorithm = $::puppet::params::digest_algorithm,
6773
$configtimeout = '2m',
6874
$stringify_facts = undef,
75+
$verbose = undef,
76+
$agent_noop = undef,
77+
$usecacheonfailure = undef,
78+
$certname = undef,
6979
) inherits puppet::params {
7080

7181
if ! defined(User[$::puppet::params::puppet_user]) {
@@ -321,4 +331,48 @@
321331
value => $stringify_facts,
322332
}
323333
}
334+
if $verbose != undef {
335+
ini_setting {'puppetagentverbose':
336+
ensure => present,
337+
setting => 'verbose',
338+
value => $verbose,
339+
}
340+
}
341+
if $agent_noop != undef {
342+
ini_setting {'puppetagentnoop':
343+
ensure => present,
344+
setting => 'noop',
345+
value => $agent_noop,
346+
}
347+
}
348+
if $usecacheonfailure != undef {
349+
ini_setting {'puppetagentusecacheonfailure':
350+
ensure => present,
351+
setting => 'usecacheonfailure',
352+
value => $usecacheonfailure,
353+
}
354+
}
355+
if $syslogfacility != undef {
356+
ini_setting {'puppetagentsyslogfacility':
357+
ensure => present,
358+
setting => 'syslogfacility',
359+
value => $syslogfacility,
360+
section => 'main',
361+
}
362+
}
363+
if $certname != undef {
364+
ini_setting {'puppetagentcertname':
365+
ensure => present,
366+
setting => 'certname',
367+
value => $certname,
368+
}
369+
}
370+
if $priority != undef {
371+
ini_setting {'puppetagentpriority':
372+
ensure => present,
373+
setting => 'priority',
374+
value => $priority,
375+
section => 'main',
376+
}
377+
}
324378
}

0 commit comments

Comments
 (0)