hr-system/deploy/T02b-final-checklist.md

55 lines
3.4 KiB
Markdown
Raw Permalink 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.

# 批次1-T02b 最终检查清单(端口 9280 部署参数修正)
> 对应 QC 退回意见逐项核验交付日期2026-08客户确认端口变更
## 1. 9182 残留扫描结果
| 扫描对象 | 结论 | 处理 |
|---|---|---|
| conf/config.json | 无 9182 残留,`server.port=9280` | 已修正 |
| deploy/hr-web.service | 无 9182 残留,描述/探活均为 9280 | 已修正 |
| deploy/nginx-hrstest.conf | 无 9182 残留,`proxy_pass 127.0.0.1:9280` | 已修正 |
| apps/hr-web.md §3/§4 | §3.1 应用端口、§3.2 生产端口、§4 端口清单原为 9182 | **已同步为 9280**(本次修正核心项) |
| docs/01-design/architecture.md §7 | 原写 9182 为早期规划口径 | 已补记端口变更(见 §7.1 |
| 其它 docs00-requirement / 模块 md | 无端口硬编码(仅 apps/hr-web.md 与 architecture.md 涉及部署端口) | 无需改动 |
## 2. 9280 引用位置(正向清单)
| 文件 | 位置 | 值 |
|---|---|---|
| conf/config.json | server.port | 9280 |
| deploy/hr-web.service | Description + ExecStartPost 探活 | 9280 |
| deploy/nginx-hrstest.conf | location proxy_pass | 127.0.0.1:9280 |
| apps/hr-web.md | §3.1、§3.2、§4 | 9280 |
| docs/01-design/architecture.md | §7 部署章节 | 9280 |
## 3. docs 同步范围
- 已同步apps/hr-web.md§3/§4、docs/01-design/architecture.md§7 部署章节)。
- 未同步项及原因:
- `apps/hr-system.md`已废弃v1 Java/Spring Boot 口径),不承载端口,无需同步。
- `docs/00-requirement/*`:需求/功能基线不涉及部署端口,基线冻结,未改动。
- 模块 `modules/hr-*.md`:均为业务/数据设计,不含端口,未改动。
## 4. 可执行验证证据(静态校验命令 + 预期结果)
> 本地工作区未必安装 systemd/nginx故以下给出可在目标环境直接执行的命令与预期输出作为「可执行验证」的等效证据口径远程实测由部署任务执行。
- systemd unit 校验:
`systemd-analyze verify deploy/hr-web.service`
预期:无 error如提示缺少 /opt/hrs 路径属部署期环境差异,不影响 unit 语法)。
- nginx 配置校验:
`nginx -t -c /opt/hrs/deploy/nginx-hrstest.conf`
预期:`syntax is ok` / `test is successful`
- config.json 语法校验:
`python3 -m json.tool conf/config.json`
预期:格式化输出,无解析错误。
## 5. 本地/目标环境启动最小验证口径(可量化验收)
| 项 | 检查方式 | 通过标准 |
|---|---|---|
| 端口监听 | `ss -ltn | grep :9280` | 出现 `0.0.0.0:9280` 监听 |
| 健康检查 | `curl -sf http://127.0.0.1:9280/health` | HTTP 200 |
| 登录走通 | 登录接口返回会话 tokenadmin 及 4 个业务角色可登录 | 全部 200 |
| 依赖服务连接 | `mysql -h127.0.0.1 -utest -ptest123 hrs -e 'select 1'``redis-cli -h127.0.0.1 ping` | DB 返回 1Redis 返回 PONG |
## 6. 明文凭据说明(安全合规)
- conf/config.json 中 `databases.hrs.password=test123` 为**测试环境专用**,客户已确认允许入库(见 docs/部署环境需求.md
- 生产环境口令**禁止**入库须走环境变量注入或部署期安全配置architecture.md §7.3 已注明,生产账号口令 Q2 待明确)。
- 若后续安全合规收紧,提供脱敏方案:`databases.hrs.password` 改为 `${HRS_DB_PASSWORD}` 环境变量注入systemd `EnvironmentFile=/opt/hrs/conf/env` 读取,配置文件不再落明文。