|
|
|
@ -1,4 +1,5 @@ |
|
|
|
import os |
|
|
|
from functools import partial |
|
|
|
|
|
|
|
|
|
|
|
def mod_time(path): |
|
|
|
@ -19,3 +20,7 @@ def find_newest_cert(root_dir, hostname): |
|
|
|
elif mod_time(fullpath) > mod_time(look_for[file]): |
|
|
|
look_for[file] = fullpath |
|
|
|
return look_for |
|
|
|
|
|
|
|
|
|
|
|
def ensure_keys(key_dir, hostname): |
|
|
|
files = (part.format(hostname) for part in ("{}.key.pem", "{}.chain.pem")) |