summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--manifests/system.pp6
-rw-r--r--templates/postfixadmin/config.inc.php.erb16
2 files changed, 14 insertions, 8 deletions
diff --git a/manifests/system.pp b/manifests/system.pp
index f5008a7..b018fc1 100644
--- a/manifests/system.pp
+++ b/manifests/system.pp
@@ -11,6 +11,12 @@ class mail::system {
'': { 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" }
}
diff --git a/templates/postfixadmin/config.inc.php.erb b/templates/postfixadmin/config.inc.php.erb
index fce9039..d694b90 100644
--- a/templates/postfixadmin/config.inc.php.erb
+++ b/templates/postfixadmin/config.inc.php.erb
@@ -28,7 +28,7 @@ $CONF['configured'] = true;
// In order to setup Postfixadmin, you MUST specify a hashed password here.
// To create the hash, visit setup.php in a browser and type a password into the field,
// on submission it will be echoed out to you as a hashed value.
-$CONF['setup_password'] = 'changeme';
+$CONF['setup_password'] = '<%= postfixadmin_setup_hash %>';
// Postfix Admin Path
// Set the location of your Postfix Admin installation here.
@@ -80,7 +80,7 @@ $CONF['database_tables'] = array (
// Site Admin
// Define the Site Admins email address below.
// This will be used to send emails from to create mailboxes.
-$CONF['admin_email'] = 'postmaster@change-this-to-your.domain.tld';
+$CONF['admin_email'] = 'postmaster@<%= domain %>';
// Mail Server
// Hostname (FQDN) of your mail server.
@@ -131,10 +131,10 @@ $CONF['page_size'] = '10';
// Default Aliases
// The default aliases that need to be created for all domains.
$CONF['default_aliases'] = array (
- 'abuse' => 'abuse@change-this-to-your.domain.tld',
- 'hostmaster' => 'hostmaster@change-this-to-your.domain.tld',
- 'postmaster' => 'postmaster@change-this-to-your.domain.tld',
- 'webmaster' => 'webmaster@change-this-to-your.domain.tld'
+ 'abuse' => 'abuse@<%= domain %>',
+ 'hostmaster' => 'hostmaster@<%= domain %>',
+ 'postmaster' => 'postmaster@<%= domain %>',
+ 'webmaster' => 'webmaster@<%= domain %>'
);
// Mailboxes
@@ -214,7 +214,7 @@ $CONF['vacation'] = 'NO';
// This is the autoreply domain that you will need to set in your Postfix
// transport maps to handle virtual vacations. It does not need to be a
// real domain (i.e. you don't need to setup DNS for it).
-$CONF['vacation_domain'] = 'autoreply.change-this-to-your.domain.tld';
+$CONF['vacation_domain'] = 'autoreply.<%= domain %>';
// Vacation Control
// If you want users to take control of vacation set this to 'YES'.
@@ -279,7 +279,7 @@ $CONF['show_header_text'] = 'NO';
$CONF['header_text'] = ':: Postfix Admin ::';
// link to display under 'Main' menu when logged in as a user.
-$CONF['user_footer_link'] = "http://change-this-to-your.domain.tld/main";
+$CONF['user_footer_link'] = "http://<%= domain %>/main";
// Footer
// Below information will be on all pages.