hi-server/说明文档.md
shanshanzhong 5898b74647
Some checks failed
Build docker and publish / build (20.15.1) (push) Has been cancelled
internal
2026-03-19 01:51:18 -07:00

34 lines
1.9 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 说明文档.md
## 项目规划
本任务旨在帮助用户在云端服务器上替换 SSL 证书。用户已解压 `airoport.co_ecc.zip`,需将得到的 `.cer``.key` 文件替换到 `/etc/letsencrypt/archive/airoport.co` 目录下对应的 `.pem` 文件中。
## 实施方案
1. **文件对应关系确认**:映射解压后的文件与 `archive` 目录下的 PEM 文件。
2. **备份与替换**:备份旧证书,执行 `cp` 命令覆盖现有文件。
3. **服务重启建议**:提示用户替换后需重启 Nginx/Gateway 服务以使证书生效。
## 进度记录
| 时间节点 | 任务说明 | 进度 | 结果说明 |
| :--- | :--- | :--- | :--- |
| 2026-03-11 | 初始化文档并提供指令 | [x] 已完成 | 已提供查找日志的命令并记录在文档中 |
| 2026-03-11 | 提供今天所有 ERROR 报错指令 | [x] 已完成 | 已提供根据日期过滤 ERROR 的命令 |
| 2026-03-12 | 分析并确认 Unknown column 错误 | [x] 已完成 | 确认为 `user_device` 缺少 `short_code` 字段,已提供 SQL |
| 2026-03-12 | 提供 SSL 证书替换指令 | [x] 已完成 | 已提供备份与替换证书的组合指令 |
| 2026-03-17 | 合并 internal 到 internal/main | [x] 已完成 | 已查验均为fast-forward受限网络/权限需手动push完成合并 |
certbot certonly --manual --preferred-challenges dns -d airoport.win -d "*.airoport.win" -d hifastapp.com
gunzip -c mysql_dump_20260318_052811.sql.gz \
| docker exec -i ppanel-mysql mysql -uroot -pjpcV41ppanel
go run scripts/migrate_paid_users.go -src 'root:rootpassword@tcp(127.0.0.1:3306)/ppanel?charset=utf8mb4&parseTime=True&loc=Local' -dst 'root:jpcV41ppanel@tcp(103.150.215.44:3306)/hifast?charset=utf8mb4&parseTime=True&loc=Local' -clean
docker exec ppanel-redis redis-cli --scan --pattern "*" \
grep -vE "^auth:session_id:|^auth:user_sessions:" \
xargs -r -n 500 docker exec -i ppanel-redis redis-cli DEL