From 08cf1b22b0268d6dc77a78f236e42a6acc0e8e16 Mon Sep 17 00:00:00 2001 From: klemek Date: Sun, 12 Apr 2026 23:40:15 +0200 Subject: [PATCH] feat: copy certbot certificates for unique path --- README.md | 2 +- src/cert.py | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 082f10a..80df3ce 100644 --- a/README.md +++ b/README.md @@ -94,7 +94,7 @@ curl -X DELETE \ - [x] renew command - [x] https mode w/ multiple hosts - [x] create certificate on request -- [ ] certbot symlink certificates for unique path +- [x] certbot copy certificates for unique path - [x] better error page - [ ] add favicon.ico + special path - [ ] [http.server security](https://docs.python.org/3/library/http.server.html#http-server-security) diff --git a/src/cert.py b/src/cert.py index 86cb70d..e41d891 100644 --- a/src/cert.py +++ b/src/cert.py @@ -156,6 +156,9 @@ class CertManager: stderr=subprocess.STDOUT, ) self.logger.info("Created certbot certificate for %s", host) + cert_path = self.certbot_conf / "live" / host + cert_path.copy_into(self.self_signed_path, follow_symlinks=False) + self.logger.debug("Copied certbot certificate to self certificates") except subprocess.CalledProcessError as e: self.logger.exception( "Could not create certbot certificate for %s\n%s",