2013-08-27 22:43:47 +02:00
|
|
|
# Install the contrib postgresql packaging. See README.md for more details.
|
2013-02-24 22:06:37 +01:00
|
|
|
class postgresql::contrib (
|
|
|
|
$package_name = $postgresql::params::contrib_package_name,
|
|
|
|
$package_ensure = 'present'
|
|
|
|
) inherits postgresql::params {
|
2013-06-06 20:39:00 +02:00
|
|
|
validate_string($package_name)
|
|
|
|
|
2013-02-24 22:06:37 +01:00
|
|
|
package { 'postgresql-contrib':
|
|
|
|
ensure => $package_ensure,
|
|
|
|
name => $package_name,
|
2013-07-17 12:10:19 +02:00
|
|
|
tag => 'postgresql',
|
2013-02-24 22:06:37 +01:00
|
|
|
}
|
2013-09-14 07:33:46 +02:00
|
|
|
|
|
|
|
if($package_ensure == 'present' or $package_ensure == true) {
|
|
|
|
anchor { 'postgresql::contrib::start': }->
|
|
|
|
Class['postgresql::server::install']->
|
|
|
|
Package['postgresql-contrib']->
|
|
|
|
Class['postgresql::server::service']->
|
|
|
|
anchor { 'postgresql::contrib::end': }
|
|
|
|
} else {
|
|
|
|
anchor { 'postgresql::contrib::start': }->
|
|
|
|
Class['postgresql::server::service']->
|
|
|
|
Package['postgresql-contrib']->
|
|
|
|
Class['postgresql::server::install']->
|
|
|
|
anchor { 'postgresql::contrib::end': }
|
|
|
|
}
|
2013-02-24 22:06:37 +01:00
|
|
|
}
|