feat: 添加 Let's Encrypt SSL 证书管理

- 新增独立 certbot 服务项目
- nginx 配置添加 HTTPS 8443 端口监听
- frpc.toml HTTPS 代理指向 nginx:8443
- 支持自动续签并重载 nginx
- 共享 Docker volume 传递证书
This commit is contained in:
awei
2026-09-08 11:43:34 +00:00
parent b028e6dd73
commit 58d65188a1
13 changed files with 341 additions and 69 deletions

View File

@@ -1,7 +1,18 @@
# HTTPS 配置
server {
listen 80;
listen 8443 ssl;
server_name www.stonelan.cn;
ssl_certificate /etc/letsencrypt/live/www.stonelan.cn/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/www.stonelan.cn/privkey.pem;
ssl_protocols TLSv1.2 TLSv1.3;
ssl_ciphers ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384;
ssl_prefer_server_ciphers off;
ssl_session_cache shared:SSL:10m;
ssl_session_timeout 1d;
ssl_session_tickets off;
location / {
proxy_pass http://10.0.3.173:8080;
proxy_set_header Host $host;
@@ -9,7 +20,6 @@ server {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
# 添加代理超时配置
proxy_connect_timeout 60s;
proxy_read_timeout 600s;
proxy_send_timeout 600s;