3 include exim::vdomain::setup
5 munin::check { 'ps_exim4': script => 'ps_' }
6 munin::check { 'exim_mailqueue': }
7 munin::check { 'exim_mailstats': }
9 munin::check { 'postfix_mailqueue': ensure => absent }
10 munin::check { 'postfix_mailstats': ensure => absent }
11 munin::check { 'postfix_mailvolume': ensure => absent }
13 package { 'exim4-daemon-heavy': ensure => installed }
15 Package['exim4-daemon-heavy']->Mailalias<| |>
17 concat::fragment { 'virtual_domain_template':
18 target => '/etc/exim4/virtualdomains',
19 content => template('exim/virtualdomains.erb'),
26 File['/etc/exim4/exim4.conf'],
27 Package['exim4-daemon-heavy'],
34 require => Package['exim4-daemon-heavy'],
37 file { '/etc/exim4/Git':
41 # git checkouts through puppet. yummy.
42 file { '/etc/exim4/email-virtualdomains':
44 source => 'puppet:///modules/exim/email-virtualdomains',
48 file { '/etc/exim4/conf.d':
53 source => 'puppet:///files/empty/',
55 file { '/etc/exim4/ssl':
61 file { '/etc/exim4/exim4.conf':
62 content => template('exim/eximconf.erb'),
63 require => File['/etc/exim4/ssl/thishost.crt'],
64 notify => Service['exim4'],
66 file { '/etc/mailname':
67 content => template('exim/mailname.erb'),
69 file { '/etc/exim4/manualroute':
70 content => template('exim/manualroute.erb')
72 file { '/etc/exim4/locals':
73 content => template('exim/locals.erb')
75 file { '/etc/exim4/submission-domains':
76 content => template('exim/submission-domains.erb'),
78 file { '/etc/exim4/host_blacklist':
79 source => 'puppet:///modules/exim/common/host_blacklist',
81 file { '/etc/exim4/blacklist':
82 source => 'puppet:///modules/exim/common/blacklist',
84 file { '/etc/exim4/callout_users':
85 source => 'puppet:///modules/exim/common/callout_users',
87 file { '/etc/exim4/grey_users':
88 source => 'puppet:///modules/exim/common/grey_users',
90 file { '/etc/exim4/helo-check':
91 source => 'puppet:///modules/exim/common/helo-check',
93 file { '/etc/exim4/localusers':
94 source => 'puppet:///modules/exim/common/localusers',
96 file { '/etc/exim4/rbllist':
97 source => 'puppet:///modules/exim/common/rbllist',
99 file { '/etc/exim4/rhsbllist':
100 source => 'puppet:///modules/exim/common/rhsbllist',
102 file { '/etc/exim4/whitelist':
103 source => 'puppet:///modules/exim/common/whitelist',
105 file { '/etc/logrotate.d/exim4-base':
106 source => 'puppet:///modules/exim/common/logrotate-exim4-base',
108 file { '/etc/logrotate.d/exim4-paniclog':
109 source => 'puppet:///modules/exim/common/logrotate-exim4-paniclog'
111 file { '/etc/exim4/ssl/thishost.crt':
112 source => "puppet:///modules/exim/certs/${::fqdn}.crt",
113 group => Debian-exim,
116 file { '/etc/exim4/ssl/thishost.key':
117 source => "puppet:///modules/exim/certs/${::fqdn}.key",
118 group => Debian-exim,
121 file { '/etc/exim4/ssl/ca.crt':
122 source => 'puppet:///modules/exim/certs/ca.crt',
123 group => Debian-exim,
126 file { '/etc/exim4/ssl/ca.crl':
127 source => 'puppet:///modules/exim/certs/ca.crl',
128 group => Debian-exim,
131 file { '/var/log/exim4':
134 owner => Debian-exim,
138 case getfromhash($site::nodeinfo, 'mail_port') {
139 /^(\d+)$/: { $mail_port = $1 }
140 default: { $mail_port = '25' }
143 @ferm::rule { 'dsa-exim':
144 description => 'Allow SMTP',
145 rule => "&SERVICE_RANGE(tcp, $mail_port, \$SMTP_SOURCES)"
148 @ferm::rule { 'dsa-exim-v6':
149 description => 'Allow SMTP',
151 rule => "&SERVICE_RANGE(tcp, $mail_port, \$SMTP_V6_SOURCES)"
153 dnsextras::tlsa_record{ 'tlsa-mailport':
154 zone => 'debian.org',
155 certfile => "/etc/puppet/modules/exim/files/certs/${::fqdn}.crt",
160 # Do we actually want this? I'm only doing it because it's harmless
161 # and makes the logs quiet. There are better ways of making logs quiet,
163 @ferm::rule { 'dsa-ident':
164 domain => '(ip ip6)',
165 description => 'Allow ident access',
166 rule => '&SERVICE(tcp, 113)'
169 # These only affect the alias @$fqdn, not say, @debian.org