deploy(M00-E): 补充Certbot证书检查
This commit is contained in:
@@ -37,6 +37,7 @@
|
||||
- EMQX:输出原生 Apt/无 Docker/MQTTX 禁止策略和本机命令状态。
|
||||
- HTTPS:输出固定域名、API 路径和 Nginx 配置检查。
|
||||
- Nginx:提供 `deploy/nginx/api.txyundm.cn.conf.template`,菜单第 4 项会检查模板、站点文件、TLS 和健康端点。
|
||||
- 证书:提供 `deploy/certbot/api.txyundm.cn.commands.md`,菜单第 4 项会检查 Certbot、证书文件、续期配置和 `certbot.timer`。
|
||||
- 非交互检查:`setup.sh --preflight`、`setup.sh --status`、`setup.sh --https`、`setup.sh --diagnose`。
|
||||
- 状态:显示部署上下文、快检、仓库状态和当前 release manifest。
|
||||
- 备份:当前生成 manifest-only 备份记录,不触碰真实数据库。
|
||||
|
||||
+1
-1
@@ -1 +1 @@
|
||||
0.1.1-m00-domain-https-check
|
||||
0.1.2-m00-certbot-check
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
# api.txyundm.cn Certbot Commands
|
||||
|
||||
This file records the production commands for the Ubuntu administrator. Do not run them from Windows or WSL.
|
||||
|
||||
## Preconditions
|
||||
|
||||
- DNS for `api.txyundm.cn` points to the production Ubuntu server.
|
||||
- Nginx serves `/.well-known/acme-challenge/` from `/var/www/certbot` on port 80.
|
||||
- Ports 80 and 443 are open.
|
||||
|
||||
## Issue
|
||||
|
||||
```bash
|
||||
sudo mkdir -p /var/www/certbot
|
||||
sudo certbot certonly --webroot -w /var/www/certbot -d api.txyundm.cn
|
||||
```
|
||||
|
||||
## Install Nginx Site
|
||||
|
||||
```bash
|
||||
sudo install -m 0644 /opt/apps/qipai-repo/deploy/nginx/api.txyundm.cn.conf.template /etc/nginx/sites-available/qipai-api.conf
|
||||
sudo ln -sfn /etc/nginx/sites-available/qipai-api.conf /etc/nginx/sites-enabled/qipai-api.conf
|
||||
sudo nginx -t
|
||||
sudo systemctl reload nginx
|
||||
```
|
||||
|
||||
## Renew Dry Run
|
||||
|
||||
```bash
|
||||
sudo certbot renew --dry-run
|
||||
```
|
||||
Reference in New Issue
Block a user