-
-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathpostfix.pp
More file actions
42 lines (42 loc) · 1.21 KB
/
Copy pathpostfix.pp
File metadata and controls
42 lines (42 loc) · 1.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#
# @summary installs postfix
#
class profiles::postfix {
# provides /etc/ssl/certs/ca-certificates.crt for smtpd_tls_CAfile ini_setting
require profiles::base
# todo: use puppet/postfix
package { 'postfix':
ensure => 'installed',
}
-> service { 'postfix.service':
ensure => 'running',
enable => true,
}
if fact('letsencrypt_directory."voxpupu.li"') {
$path = fact('letsencrypt_directory."voxpupu.li"')
ini_setting { 'smtpd_tls_cert_file':
ensure => 'present',
path => '/etc/postfix/main.cf',
section => '',
setting => 'smtpd_tls_cert_file',
value => "${path}/fullchain.pem",
notify => Service['postfix.service'],
}
ini_setting { 'smtpd_tls_key_file':
ensure => 'present',
path => '/etc/postfix/main.cf',
section => '',
setting => 'smtpd_tls_key_file',
value => "${path}/privkey.pem",
notify => Service['postfix.service'],
}
ini_setting { 'smtpd_tls_CAfile':
ensure => 'present',
path => '/etc/postfix/main.cf',
section => '',
setting => 'smtpd_tls_CAfile',
value => '/etc/ssl/certs/ca-certificates.crt',
notify => Service['postfix.service'],
}
}
}