summaryrefslogtreecommitdiff
path: root/puppet/modules/leap_mx
diff options
context:
space:
mode:
Diffstat (limited to 'puppet/modules/leap_mx')
-rw-r--r--puppet/modules/leap_mx/manifests/init.pp24
-rw-r--r--puppet/modules/leap_mx/templates/mx.conf.erb2
2 files changed, 19 insertions, 7 deletions
diff --git a/puppet/modules/leap_mx/manifests/init.pp b/puppet/modules/leap_mx/manifests/init.pp
index 5561e326..9c1b9143 100644
--- a/puppet/modules/leap_mx/manifests/init.pp
+++ b/puppet/modules/leap_mx/manifests/init.pp
@@ -15,18 +15,29 @@ class leap_mx {
#
# USER AND GROUP
#
+ # Make the user for leap-mx. This user is where all legitimate, non-system
+ # mail is delivered so leap-mx can process it. Previously, we let the system
+ # pick a uid/gid, but we need to know what they are set to in order to set the
+ # virtual_uid_maps and virtual_gid_maps. Its a bit overkill write a fact just
+ # for this, so instead we pick arbitrary numbers that seem unlikely to be used
+ # and then use them in the postfix configuration
group { 'leap-mx':
ensure => present,
+ gid => 42424,
allowdupe => false;
}
user { 'leap-mx':
- ensure => present,
- allowdupe => false,
- gid => 'leap-mx',
- home => '/etc/leap',
- require => Group['leap-mx'];
+ ensure => present,
+ comment => 'Leap Mail',
+ allowdupe => false,
+ uid => 42424,
+ gid => 'leap-mx',
+ home => '/var/mail/leap-mx',
+ shell => '/bin/false',
+ managehome => true,
+ require => Group['leap-mx'];
}
#
@@ -52,7 +63,8 @@ class leap_mx {
ensure => $sources['leap-mx']['revision'],
require => [
Class['site_apt::preferences::twisted'],
- Class['site_apt::leap_repo'] ];
+ Class['site_apt::leap_repo']
+ User['leap-mx'] ];
'leap-keymanager':
ensure => latest;
diff --git a/puppet/modules/leap_mx/templates/mx.conf.erb b/puppet/modules/leap_mx/templates/mx.conf.erb
index e05bc150..a2c293c6 100644
--- a/puppet/modules/leap_mx/templates/mx.conf.erb
+++ b/puppet/modules/leap_mx/templates/mx.conf.erb
@@ -1,5 +1,5 @@
[mail1]
-path=/var/mail/vmail/Maildir
+path=/var/mail/leap-mx/Maildir
recursive=True
[couchdb]