summaryrefslogtreecommitdiff
path: root/manifests/postfixadmin.pp
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/postfixadmin.pp')
-rw-r--r--manifests/postfixadmin.pp29
1 files changed, 29 insertions, 0 deletions
diff --git a/manifests/postfixadmin.pp b/manifests/postfixadmin.pp
index be3e312..e00d8ce 100644
--- a/manifests/postfixadmin.pp
+++ b/manifests/postfixadmin.pp
@@ -1,4 +1,28 @@
class mail::postfixadmin {
+ # Class configuration
+ case $postfixadmin_database_password {
+ '': { fail("You need to define \$postfixadmin_database_password host config") }
+ }
+
+ case $postfixadmin_setup_hash {
+ '': {
+ warning("You need to define \$postfixadmin_setup_hash host config")
+ $postfixadmin_setup_hash = 'changeme'
+ }
+ }
+
+ case $postfixadmin_database_user {
+ '': { $postfixadmin_database_user = "postfix" }
+ }
+
+ case $postfixadmin_database_host {
+ '': { $postfixadmin_database_host = "localhost" }
+ }
+
+ case $postfixadmin_database_name {
+ '': { $postfixadmin_database_name= "postfix" }
+ }
+
#
# Database configuration
#
@@ -9,6 +33,11 @@ class mail::postfixadmin {
#
# Postfix configuration
#
+ postfix::config {
+ "virtual_transport": value => 'dovecot';
+ "dovecot_destination_recipient_limit": value => '1';
+ }
+
postfix::config { "virtual_mailbox_domains":
value => 'proxy:mysql:/etc/postfix/sql/mysql_virtual_domains_maps.cf',
require => File['/etc/postfix/sql/mysql_virtual_domains_maps.cf'],