bundles/nginx: use DEFAULTS for letsencrypt
This commit is contained in:
parent
ce0af62968
commit
31a1a88d13
1 changed files with 9 additions and 6 deletions
|
@ -31,13 +31,16 @@ def letsencrypt(metadata):
|
|||
if not node.has_bundle('letsencrypt'):
|
||||
return metadata, DONE
|
||||
|
||||
le = metadata.setdefault('letsencrypt', {})
|
||||
domains = le.setdefault('domains', {})
|
||||
domains = {}
|
||||
|
||||
for domain in metadata.get('nginx', {}).get('vhosts', {}).keys():
|
||||
domains[domain] = set()
|
||||
|
||||
reload = le.setdefault('reload_after', set())
|
||||
reload.add('nginx')
|
||||
|
||||
return metadata, RUN_ME_AGAIN
|
||||
return {
|
||||
'letsencrypt': {
|
||||
'domains': domains,
|
||||
'reload_after': {
|
||||
'nginx',
|
||||
},
|
||||
},
|
||||
}, DEFAULTS, RUN_ME_AGAIN
|
||||
|
|
Loading…
Reference in a new issue