bundles/postfix: introduce
This commit is contained in:
parent
88afba9ce9
commit
5550d2cc56
4 changed files with 208 additions and 0 deletions
33
bundles/postfix/items.py
Normal file
33
bundles/postfix/items.py
Normal file
|
@ -0,0 +1,33 @@
|
|||
if node.has_bundle('postfixadmin'):
|
||||
assert node.has_bundle('letsencrypt')
|
||||
|
||||
files = {
|
||||
'/etc/mailname': {
|
||||
'content': node.metadata.get('postfix', {}).get('myhostname', node.metadata['hostname']),
|
||||
'triggers': {
|
||||
'svc_systemd:postfix:restart',
|
||||
},
|
||||
},
|
||||
'/etc/postfix/master.cf': {
|
||||
'content_type': 'mako',
|
||||
'triggers': {
|
||||
'svc_systemd:postfix:restart',
|
||||
},
|
||||
},
|
||||
'/etc/postfix/main.cf': {
|
||||
'content_type': 'mako',
|
||||
'triggers': {
|
||||
'svc_systemd:postfix:restart',
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
svc_systemd = {
|
||||
'postfix': {
|
||||
'needs': {
|
||||
'file:/etc/postfix/master.cf',
|
||||
'file:/etc/postfix/main.cf',
|
||||
'pkg_apt:',
|
||||
},
|
||||
},
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue