Skip to content
This repository was archived by the owner on Mar 28, 2019. It is now read-only.

Commit 8c1fc72

Browse files
committed
Make the inclusion of a service config optional.
This commit will make it so that the service config is not required on all platforms. Without this we can't support Solaris.
1 parent 4fd6c35 commit 8c1fc72

File tree

1 file changed

+13
-11
lines changed

1 file changed

+13
-11
lines changed

manifests/agent/service.pp

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -38,18 +38,20 @@
3838
}
3939
default: {
4040

41-
$file_ensure = $puppet::params::agent_service_conf ? {
42-
undef => 'absent',
43-
default => 'present',
44-
}
41+
if $puppet::params::agent_service_conf {
42+
$file_ensure = $puppet::params::agent_service_conf ? {
43+
undef => 'absent',
44+
default => 'present',
45+
}
4546

46-
file { 'puppet_agent_service_conf':
47-
ensure => $file_ensure,
48-
mode => '0644',
49-
owner => 'root',
50-
group => 'root',
51-
content => template('puppet/agent_service.erb'),
52-
path => $puppet::params::agent_service_conf,
47+
file { 'puppet_agent_service_conf':
48+
ensure => $file_ensure,
49+
mode => '0644',
50+
owner => 'root',
51+
group => 'root',
52+
content => template('puppet/agent_service.erb'),
53+
path => $puppet::params::agent_service_conf,
54+
}
5355
}
5456
}
5557
}

0 commit comments

Comments
 (0)