/[adm]/puppet/modules/postfix/manifests/init.pp
ViewVC logotype

Contents of /puppet/modules/postfix/manifests/init.pp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1642 - (show annotations) (download)
Thu May 26 08:15:52 2011 UTC (12 years, 10 months ago) by misc
File size: 3139 byte(s)
give aliases to people in mga-council group, to let
trish have one until we finish the ldap setup of comm team,see #1345

1 class postfix {
2
3 class base {
4 package { postfix:
5 ensure => installed
6 }
7 package { 'nail':
8 ensure => installed
9 }
10 service { postfix:
11 ensure => running,
12 subscribe => [ Package['postfix']],
13 path => "/etc/init.d/postfix"
14 }
15 }
16
17 file { '/etc/postfix/main.cf':
18 ensure => present,
19 owner => root,
20 group => root,
21 mode => 644,
22 require => Package["postfix"],
23 content => "",
24 notify => [Service['postfix']]
25 }
26
27
28 class simple_relay inherits base {
29 file { '/etc/postfix/main.cf':
30 content => template("postfix/simple_relay_main.cf"),
31 }
32 }
33
34 class smtp_server inherits base {
35 include postgrey
36 include amavis
37 include spamassassin
38 file { '/etc/postfix/main.cf':
39 content => template("postfix/main.cf"),
40 }
41
42 file { '/etc/postfix/transport_regexp':
43 ensure => present,
44 owner => root,
45 group => root,
46 mode => 644,
47 content => template("postfix/transport_regexp"),
48 }
49
50 }
51
52 class primary_smtp inherits smtp_server {
53 file { '/etc/postfix/master.cf':
54 ensure => present,
55 owner => root,
56 group => root,
57 mode => 644,
58 content => template("postfix/primary_master.cf"),
59 }
60
61 package { "postfix-ldap":
62 ensure => installed
63 }
64 # council is here until we fully decide who has aliases in com team,
65 # see https://bugs.mageia.org/show_bug.cgi?id=1345
66 $aliases_group = ['mga-founders','mga-packagers','mga-sysadmin','mga-council']
67 $ldap_password = extlookup("postfix_ldap",'x')
68 file { '/etc/postfix/ldap_aliases.conf':
69 ensure => present,
70 owner => root,
71 group => root,
72 mode => 644,
73 content => template("postfix/ldap_aliases.conf"),
74 }
75
76 # TODO merge the file with the previous one, for common part (ldap, etc)
77 file { '/etc/postfix/group_aliases.conf':
78 ensure => present,
79 owner => root,
80 group => root,
81 mode => 644,
82 content => template("postfix/group_aliases.conf"),
83 }
84
85 # TODO make it conditional to the presence of sympa
86 file { '/etc/postfix/sympa_aliases':
87 ensure => present,
88 owner => root,
89 group => root,
90 mode => 644,
91 content => template("postfix/sympa_aliases"),
92 }
93
94
95
96
97 file { '/etc/postfix/virtual_aliases':
98 ensure => present,
99 owner => root,
100 group => root,
101 mode => 644,
102 content => template("postfix/virtual_aliases"),
103 }
104
105 exec { "postmap /etc/postfix/virtual_aliases":
106 refreshonly => true,
107 subscribe => File['/etc/postfix/virtual_aliases'],
108 }
109 }
110
111
112 class secondary_smtp inherits smtp_server {
113 }
114
115 }

  ViewVC Help
Powered by ViewVC 1.1.30