deploy(M00-E): 补充Certbot证书检查

This commit is contained in:
Codex
2026-06-15 16:42:42 +08:00
parent d9d51e9d67
commit 4cb3ab6529
19 changed files with 158 additions and 24 deletions
+31
View File
@@ -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
```