修复:同步SIT数据源覆盖凭据
发布 Nacos 配置 / publish (push) Successful in 29s
环境分支晋级检查 / environment-promotion-source (pull_request_target) Successful in 1s

This commit is contained in:
2026-10-12 11:38:01 +08:00
parent 66b9e2dc2d
commit e18c2b06d5
4 changed files with 10 additions and 7 deletions
@@ -7,19 +7,21 @@
Salon SIT 自动发布工作流完成构建和文件部署后失败:
- Core 使用 Nacos 中的 `rabbitmq` 账号连接 `192.168.10.13:5672`,但 SIT RabbitMQ 尚未创建该业务账号,监听器认证失败并导致应用退出。
- RabbitMQ 修复后,业务接口仍因 MySQL 认证失败而超时。Salon 和 ArtList 的 SIT `infra.yaml` 同时保留了错误地址 `192.168.10.102` 和旧密码。
- RabbitMQ 修复后,业务接口仍因 MySQL 认证失败而超时。Salon 和 ArtList 的 SIT `infra.yaml` 同时保留了错误地址 `192.168.10.102` 和旧密码,`secret.yaml` 中的 `spring.datasource.password` 也会后加载并覆盖 `infra.yaml` 的新值。
## 处理
- 在 SIT RabbitMQ 创建与 Nacos 配置一致的 `rabbitmq` 业务账号,只授予 `/jayucloud-salon-sit` vhost 的配置、写入和读取权限,不授予管理员标签。
- 将 Salon、ArtList 的 SIT `database.business.jdbc-url` 统一修正为 `192.168.10.11:3306`。
- 将两套 SIT `database.business` 的 root 密码同步为当前中间件信息表中的 MySQL 凭据。
- 将两套 SIT `database.business`、`security.database` 和 `spring.datasource` 的 root 密码同步为当前中间件信息表中的 MySQL 凭据。
- 普通业务参数继续由 Nacos 提供,应用服务器环境变量不增加 MySQL 或 RabbitMQ 参数。
- 清理 Salon Core systemd 环境文件中的 MySQL、RabbitMQ、Redis 和对象存储覆盖项,仅保留 Nacos 启动引导参数与服务端口;MessageHub Token 继续由独立的受限环境文件提供。
## 验证
- RabbitMQ 业务账号认证成功,且仅在 `/jayucloud-salon-sit` vhost 具备权限。
- MySQL 当前凭据在 `192.168.10.11` 本机认证成功,存在允许远程连接的 `root@'%'`。
- 校验 Nacos `infra.yaml` 中的 MySQL 密码与信息表一致,并确认 `secret.yaml` 不再以旧值覆盖数据源密码。
- Nacos 发布后重启 Salon Core,确认 RabbitMQ、MySQL 连接不再出现认证失败。
- 验证 Core、Gateway、公网健康检查和 `/api/shop/list`。
- 重跑失败的 Salon SIT 自动发布工作流并确认成功。
+2 -1
View File
@@ -146,7 +146,8 @@
# 2026-10-12 SIT 中间件业务账号修复
- 补齐 Salon SIT RabbitMQ `rabbitmq` 业务账号及 `/jayucloud-salon-sit` vhost 权限。
- 修正 Salon、ArtList 两套 SIT Nacos 配置中的 MySQL 地址和 root 凭据。
- 修正 Salon、ArtList 两套 SIT Nacos `infra.yaml` 与 `secret.yaml` 中的 MySQL 地址和 root 凭据,避免后加载配置覆盖新值。
- 清理 Salon Core 服务器中间件环境变量覆盖项,仅保留 Nacos 启动引导参数、服务端口和独立注入的 MessageHub Token。
- 新增说明:`docs/scripts/SIT中间件业务账号修复_20261012.md`。
# 2026-10-12 Gitea 环境分支保护设计
@@ -4,7 +4,7 @@ security:
password: 122503wcy....
database:
username: root
password: 122503wcy
password: 122503wcy....
redis:
password: 122503wcy
rabbitmq:
@@ -14,4 +14,4 @@ security:
spring:
datasource:
username: root
password: 122503wcy
password: 122503wcy....
@@ -4,7 +4,7 @@ security:
password: 122503wcy....
database:
username: root
password: 122503wcy
password: 122503wcy....
redis:
password: 122503wcy
rabbitmq:
@@ -14,4 +14,4 @@ security:
spring:
datasource:
username: root
password: 122503wcy
password: 122503wcy....