summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--manifests/base.pp13
-rw-r--r--manifests/centos.pp2
-rw-r--r--manifests/expire.pp14
-rw-r--r--manifests/init.pp1
-rw-r--r--manifests/managesieve.pp2
-rw-r--r--manifests/munin.pp2
-rw-r--r--manifests/quota.pp2
-rw-r--r--manifests/sieve.pp20
-rw-r--r--manifests/sql.pp2
9 files changed, 31 insertions, 27 deletions
diff --git a/manifests/base.pp b/manifests/base.pp
index 34728f3..1cd9996 100644
--- a/manifests/base.pp
+++ b/manifests/base.pp
@@ -1,20 +1,23 @@
class dovecot::base {
+ package{'dovecot':
+ ensure => installed,
+ }
- file { '/etc/dovecot.conf':
+ file{'/etc/dovecot.conf':
source => [ "puppet:///modules/site_dovecot/config/${::fqdn}/dovecot.conf",
"puppet:///modules/site_dovecot/config/${::dovecot::type}/dovecot.conf",
'puppet:///modules/site_dovecot/config/dovecot.conf',
"puppet:///modules/dovecot/config/${::operatingsystem}/dovecot.conf",
'puppet:///modules/dovecot/config/dovecot.conf' ],
require => Package['dovecot'],
- notify => Service['dovecot'],
+ notify => Service['dovecot'],
owner => root,
group => mail,
mode => '0644';
}
file { 'dovecot_config_dir':
- ensure => directory,
+ ensure => directory,
path => '/etc/dovecot/conf.d',
require => Package['dovecot'],
owner => dovecot,
@@ -26,7 +29,7 @@ class dovecot::base {
'/var/log/dovecot':
ensure => directory,
require => Package['dovecot'],
- before => Service['dovecot'],
+ before => Service['dovecot'],
owner => dovecot,
group => dovecot,
mode => '0750';
@@ -47,7 +50,7 @@ class dovecot::base {
include dovecot::logrotate
- service { 'dovecot':
+ service{'dovecot':
ensure => running,
enable => true,
}
diff --git a/manifests/centos.pp b/manifests/centos.pp
index 43c4f00..34ccdbf 100644
--- a/manifests/centos.pp
+++ b/manifests/centos.pp
@@ -1,6 +1,6 @@
class dovecot::centos inherits dovecot::base {
- file { '/etc/sysconfig/dovecot':
+ file{'/etc/sysconfig/dovecot':
source => [ "puppet:///modules/site_dovecot/sysconfig/${fqdn}/dovecot",
"puppet:///modules/site_dovecot/sysconfig/${dovecot::type}/dovecot",
"puppet:///modules/site_dovecot/sysconfig/dovecot",
diff --git a/manifests/expire.pp b/manifests/expire.pp
index bd1a043..7eb5c6a 100644
--- a/manifests/expire.pp
+++ b/manifests/expire.pp
@@ -1,6 +1,6 @@
class dovecot::expire ( $type = 'sqlite', $mail_location = '', $dirs = '', $days = '' ) {
- file { '/etc/cron.daily/dovecot-expire':
+ file{'/etc/cron.daily/dovecot-expire':
owner => root, group => 0, mode => 0755;
}
@@ -28,10 +28,10 @@ class dovecot::expire ( $type = 'sqlite', $mail_location = '', $dirs = '', $days
}
}
default: {
- File['/etc/cron.daily/dovecot-expire']{
- content => "dovecot --exec-mail ext /usr/libexec/dovecot/expire-tool.sh\n"
- }
- }
+ File['/etc/cron.daily/dovecot-expire']{
+ content => "dovecot --exec-mail ext /usr/libexec/dovecot/expire-tool.sh\n"
+ }
+ }
}
} else {
# dovecot version 2 way (no mail_location, dirs need to be space separated variables and expire script runs doveadm expunge)
@@ -47,7 +47,7 @@ class dovecot::expire ( $type = 'sqlite', $mail_location = '', $dirs = '', $days
}
}
}
-
+
if $type != 'legacy' and $type != 'mysql' and $version != 2 {
file{'/etc/dovecot-expire.conf':
source => [ "puppet:///modules/site_dovecot/expire/${fqdn}/dovecot-expire.conf",
@@ -59,7 +59,7 @@ class dovecot::expire ( $type = 'sqlite', $mail_location = '', $dirs = '', $days
owner => root, group => 0, mode => 0600;
}
- file { '/usr/libexec/dovecot/expire-tool.sh':
+ file{'/usr/libexec/dovecot/expire-tool.sh':
source => "puppet:///modules/dovecot/expire/expire-tool.sh",
owner => root, group => 0, mode => 0700;
}
diff --git a/manifests/init.pp b/manifests/init.pp
index 2ed1765..29d6da7 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -1,3 +1,4 @@
+# we take rpms from fedora
class dovecot(
$type = 'some_unkown_type',
$sqlite = false,
diff --git a/manifests/managesieve.pp b/manifests/managesieve.pp
index 95167d0..625de4a 100644
--- a/manifests/managesieve.pp
+++ b/manifests/managesieve.pp
@@ -2,7 +2,7 @@ class dovecot::managesieve(
$type = 'some_unknown_type',
$manage_shorewall = true,
$nagios_checks = {
- 'sieve-hostname' => $fqdn,
+ 'sieve-hostname' => $::fqdn,
}
) {
diff --git a/manifests/munin.pp b/manifests/munin.pp
index 006a10a..5996604 100644
--- a/manifests/munin.pp
+++ b/manifests/munin.pp
@@ -1,6 +1,6 @@
class dovecot::munin {
- munin::plugin::deploy { 'dovecot':
+ munin::plugin::deploy{'dovecot':
source => "dovecot/munin/dovecot",
config => "env.logfile /var/log/dovecot/dovecot.log\ngroup dovecot"
}
diff --git a/manifests/quota.pp b/manifests/quota.pp
index 6bd1ea0..c44e0c1 100644
--- a/manifests/quota.pp
+++ b/manifests/quota.pp
@@ -1,6 +1,6 @@
class dovecot::quota {
- file { '/usr/libexec/dovecot/quota-warning.sh':
+ file{'/usr/libexec/dovecot/quota-warning.sh':
source => [ "puppet:///modules/site_dovecot/quota/quota-warning.sh",
"puppet:///modules/dovecot/quota/quota-warning.sh" ],
require => Package['dovecot'],
diff --git a/manifests/sieve.pp b/manifests/sieve.pp
index 740328a..5666420 100644
--- a/manifests/sieve.pp
+++ b/manifests/sieve.pp
@@ -2,7 +2,7 @@ class dovecot::sieve {
include ::dovecot
- package { 'dovecot-sieve':
+ package{'dovecot-sieve':
ensure => installed,
before => Service['dovecot'],
}
@@ -18,19 +18,19 @@ class dovecot::sieve {
owner => root, group => mail, mode => 0775;
"${sieve_location}/global":
- ensure => directory,
- recurse => true,
- purge => true,
- force => true,
- notify => Exec['compile_global_sieve'],
- owner => root, group => root, mode => 0644;
+ ensure => directory,
+ recurse => true,
+ purge => true,
+ force => true,
+ notify => Exec['compile_global_sieve'],
+ owner => root, group => root, mode => 0644;
"${sieve_location}/default.sieve":
source => [ "puppet:///modules/site_dovecot/sieve/${fqdn}/default.sieve",
"puppet:///modules/site_dovecot/sieve/default.sieve",
"puppet:///modules/dovecot/sieve/${operatingsystem}/default.sieve",
- "puppet:///modules/dovecot/sieve/default.sieve" ],
- notify => Exec['compile_default_sieve'],
+ "puppet:///modules/dovecot/sieve/default.sieve" ],
+ notify => Exec['compile_default_sieve'],
owner => root, group => root, mode => 0644;
# this is for sequential sieve scripts, configured in 90-sieve.conf as:
@@ -51,7 +51,7 @@ class dovecot::sieve {
"puppet:///modules/dovecot/sieve/${operatingsystem}/after.sieve",
"puppet:///modules/dovecot/sieve/after.sieve" ],
notify => Exec['compile_after_sieve'],
- owner => root, group => root, mode => 0644;
+ owner => root, group => root, mode => 0644;
}
exec {
diff --git a/manifests/sql.pp b/manifests/sql.pp
index 3b2799c..b35ebdc 100644
--- a/manifests/sql.pp
+++ b/manifests/sql.pp
@@ -1,6 +1,6 @@
class dovecot::sql {
- file { '/etc/dovecot-sql.conf':
+ file{'/etc/dovecot-sql.conf':
source => [ "puppet:///modules/site_dovecot/sql/${fqdn}/dovecot-sql.conf",
"puppet:///modules/site_dovecot/sql/${dovecot::type}/dovecot-sql.conf",
"puppet:///modules/site_dovecot/sql/dovecot-sql.conf",