Add lego certificate service to ansible
This commit is contained in:
parent
5246a6b101
commit
068a8e2cd7
13 changed files with 212 additions and 0 deletions
filter_plugins
18
filter_plugins/acmedns_to_lego.py
Normal file
18
filter_plugins/acmedns_to_lego.py
Normal file
|
@ -0,0 +1,18 @@
|
|||
class FilterModule(object):
|
||||
def filters(self):
|
||||
return {
|
||||
'acmedns_to_lego': self.acmedns_to_lego,
|
||||
}
|
||||
|
||||
def acmedns_to_lego(self, acmedns_registered):
|
||||
result = {}
|
||||
for (key, value) in acmedns_registered.items():
|
||||
result[key] = {
|
||||
"fulldomain": value["subd"] + "." + value["host"],
|
||||
"subdomain": value["subd"],
|
||||
"username": value["user"],
|
||||
"password": value["pass"],
|
||||
"server_url": "https://" + value["host"]
|
||||
}
|
||||
|
||||
return result
|
Reference in a new issue