Create a httpd::mod defined type
This allows for before => Service['httpd'] on every resource without being explicit. Co-Authored-By: Bruno Tavares <btavare@thoughtworks.com> Co-Authored-By: Glauco Oliveira <gvinici@thoughtworks.com> Change-Id: I0e991a7a63317e608cc6ef35b58dc79b518ba863
This commit is contained in:
parent
2016285e71
commit
5b0ebdf555
17
manifests/mod.pp
Normal file
17
manifests/mod.pp
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
# defined type to wrap httpd_mod
|
||||||
|
# httpd_mod doesn't ensure that the service is up first, this does
|
||||||
|
define httpd::mod (
|
||||||
|
$ensure = present,
|
||||||
|
) {
|
||||||
|
|
||||||
|
if $::osfamily == 'Debian' {
|
||||||
|
httpd_mod { $name:
|
||||||
|
ensure => $ensure,
|
||||||
|
notify => Service['httpd'],
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if $::osfamily == 'RedHat' {
|
||||||
|
debug('Enabling modules is a noop on redhat, doing nothing')
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user