Merge pull request 'issue/certif_add_chain' (#4) from gnunux/risotto:issue/certif_add_chain into main

Reviewed-on: https://cloud.silique.fr/gitea/risotto/risotto/pulls/4
This commit is contained in:
gnunux@silique.fr 2022-03-15 11:57:00 +00:00
commit c8430f440e

View file

@ -90,6 +90,8 @@ def _gen_cert(is_ca,
with open(cert_file, "wt") as f: with open(cert_file, "wt") as f:
f.write(dump_certificate(FILETYPE_PEM, cert).decode("utf-8")) f.write(dump_certificate(FILETYPE_PEM, cert).decode("utf-8"))
if not is_ca:
f.write(dump_certificate(FILETYPE_PEM, ca_cert).decode("utf-8"))
with open(key_file, "wt") as f: with open(key_file, "wt") as f:
f.write(dump_privatekey(FILETYPE_PEM, key).decode("utf-8")) f.write(dump_privatekey(FILETYPE_PEM, key).decode("utf-8"))