[feat] add ACME-based certificate management using go-acme/lego

- Introduced a new `legoManager` for managing per-domain TLS certificates.
- Implemented ACME HTTP-01 challenge handling with a configurable webroot directory.
- Created `NewLegoManagerFromEnv` to initialize ACME settings from environment variables.
- Added `verifyDomainsResolve` to validate domain DNS resolutions.
- Updated `.gitignore` to include ACME cache and webroot directories.
- Updated `go.mod` and `go.sum` with new dependencies, including `go-acme/lego`.
This commit is contained in:
dalbodeule
2025-11-27 01:23:12 +09:00
parent 694b0feaae
commit 0f32593ea5
10 changed files with 1204 additions and 55 deletions

4
.gitignore vendored
View File

@@ -192,4 +192,6 @@ $RECYCLE.BIN/
# End of https://www.toptal.com/developers/gitignore/api/go,goland+all,dotenv,macos,linux,windows
# builded binary
bin/
bin/
acme-cache/
acme-webroot/