Some controls improvements for certbot.
This commit is contained in:
parent
c86d4a02e9
commit
22cac26555
6 changed files with 70 additions and 31 deletions
|
|
@ -47,6 +47,7 @@ class HaproxyConfigGenerator:
|
|||
self.label = DockerLabelHandler(mapping['lookup_label'] if 'lookup_label' in mapping else "easyhaproxy")
|
||||
self.ssl_cert_folder = ssl_cert_folder
|
||||
self.letsencrypt_hosts = []
|
||||
self.letsencrypt_email = os.getenv("EASYHAPROXY_LETSENCRYPT_EMAIL", "")
|
||||
os.makedirs(self.ssl_cert_folder, exist_ok=True)
|
||||
|
||||
|
||||
|
|
@ -108,7 +109,7 @@ class HaproxyConfigGenerator:
|
|||
letsencrypt = self.label.get_bool(
|
||||
self.label.create([definition, "letsencrypt"]),
|
||||
False
|
||||
)
|
||||
) and self.letsencrypt_email != ""
|
||||
self.letsencrypt_hosts.append(d[host_label]) if letsencrypt and d[host_label] not in self.letsencrypt_hosts else self.letsencrypt_hosts
|
||||
|
||||
if port not in easymapping:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue