docs: 添加完整的系统凭证和访问信息文档

## 更新内容

### 1. monitoring/README.md
新增"🔐 系统凭证"专门章节,包含:

**监控系统凭证**:
- Grafana: admin/admin123 (可修改)
- Prometheus: 无需认证(内网访问)
- Alertmanager: 无需认证(内网访问)
- Loki: 无需认证(内网访问)

**ljwx-bigscreen应用**:
- Web界面: 企业微信登录
- 指标端点: /metrics (无需认证)

**数据库连接信息**:
- MySQL: 127.0.0.1:3306/test (root/123456)
- Redis: 127.0.0.1:6379 (无密码)

**企业微信配置**:
- AppID和AppSecret环境变量配置
- 用于告警通知和用户认证

**Docker Registry**:
- Aliyun容器镜像服务访问信息

**安全建议**:
- 7条生产环境安全最佳实践
- 密码修改、权限限制、网络隔离等

### 2. bigscreen/README.md
在"核心特性"之后新增"🔐 快速访问与系统凭证"章节:

**主要服务访问表格**:
- ljwx-bigscreen、Grafana、Prometheus、Alertmanager
- 访问地址、凭证、功能说明一目了然

**数据库连接**:
- MySQL和Redis配置信息
- 代码块格式,易于复制使用

**监控系统快速启动**:
- 引用 monitoring/README.md 详细文档
- docker-compose 一键启动命令

**安全提示**:
- 生产环境部署前的4条关键安全建议

### 3. CLAUDE.md
在"Performance Monitoring"和"Core Architecture"之间新增"System Access & Credentials"章节:

**Application Services表格**:
- 包含URL、凭证、用途的完整服务清单
- 面向开发者的专业英文文档

**Database Credentials**:
- MySQL和Redis连接信息
- 标准化的代码块格式

**Monitoring System**:
- Docker Compose快速启动指南
- 关键端点列表(dashboards, queries, targets, alerts)
- 监控系统功能概述

**Port Mappings**:
- 详细说明端口冲突避免策略
- 解释为什么使用非标准端口
- 列出冲突的系统服务

**Security Notes**:
- 明确标注开发/测试环境凭证
- 生产环境部署安全检查清单

## 文档改进

**统一性**:
- 三份文档中凭证信息保持一致
- 中英文文档都包含完整信息

**可访问性**:
- README.md 面向用户,简洁直观
- monitoring/README.md 面向运维,详细完整
- CLAUDE.md 面向开发者,包含技术细节

**安全意识**:
- 所有文档都强调生产环境安全
- 提供具体的安全建议和检查清单

## 用户体验改进

✅ **快速查找**: 系统凭证集中展示,无需翻阅多处
✅ **复制友好**: 使用代码块格式,便于复制粘贴
✅ **表格清晰**: 服务访问信息一目了然
✅ **安全提醒**: 每处都有明显的安全警告
✅ **引用完整**: 详细文档相互引用,信息不重复

🚀 Generated with Claude Code

Co-Authored-By: Claude <[email protected]>
This commit is contained in:
2025-11-25 14:17:18 +08:00
co-authored by Claude
parent 4cedb69175
commit fca0ddcc68
3 changed files with 201 additions and 2 deletions
+70
View File
@@ -82,6 +82,76 @@ python queue_stress_test.py
# Navigate to http://localhost:5225/performance_test_report (local) or http://localhost:5001/performance_test_report (Docker)
```
## System Access & Credentials
### Application Services
| Service | URL | Credentials | Purpose |
|---------|-----|-------------|---------|
| ljwx-bigscreen | http://localhost:5225<br>http://192.168.1.83:5225 | WeChat Enterprise Login | Main health monitoring dashboard |
| Grafana | http://localhost:3001 | admin / admin123 | Monitoring visualization |
| Prometheus | http://localhost:9091 | No auth required | Metrics collection |
| Alertmanager | http://localhost:9094 | No auth required | Alert management |
### Database Credentials
**MySQL**
```
Host: 127.0.0.1
Port: 3306
Database: test
Username: root
Password: 123456
```
**Redis**
```
Host: 127.0.0.1 or 192.168.1.6
Port: 6379
Password: (none)
```
### Monitoring System
The complete monitoring stack is deployed via Docker Compose in the `monitoring/` directory.
**Quick Start:**
```bash
cd bigscreen/monitoring
docker-compose up -d
```
**Key Endpoints:**
- Grafana dashboards: http://localhost:3001 (admin/admin123)
- Prometheus queries: http://localhost:9091/graph
- Prometheus targets: http://localhost:9091/targets
- Alertmanager: http://localhost:9094/#/alerts
- Application metrics: http://localhost:5225/metrics
**Documentation:**
- Full monitoring setup guide: `bigscreen/monitoring/README.md`
- Includes Prometheus, Loki, Grafana, Alertmanager
- Pre-configured dashboards for health data, API performance, alerts
- 15+ alert rules for application and system monitoring
### Port Mappings (Avoiding Conflicts)
The monitoring system uses non-standard ports to avoid conflicts:
- Prometheus: 9091 (not 9090 - conflicts with OrbStack)
- Alertmanager: 9094 (not 9093 - conflicts with ClashX)
- Node Exporter: 9101 (not 9100 - conflicts with OrbStack)
- Grafana: 3001 (standard)
- Loki: 3100 (standard)
### Security Notes
⚠️ **IMPORTANT**: These are development/testing credentials
- **Production**: Change all default passwords before deployment
- **Grafana**: Change admin password on first login
- **MySQL**: Create dedicated app user with limited privileges
- **Redis**: Enable password authentication for production
- **Network**: Keep monitoring services on internal network only
## Core Architecture
### Main Application Structure
+49
View File
@@ -20,6 +20,55 @@ LJWX BigScreen 是一个专为工业环境设计的实时健康监控大屏系
- **🐳 多架构Docker支持**:AMD64/ARM64一键部署
- **📈 性能监控面板**:实时系统状态和性能指标
## 🔐 快速访问与系统凭证
### 主要服务访问
| 服务 | 访问地址 | 凭证 | 说明 |
|------|---------|------|------|
| **ljwx-bigscreen** | http://localhost:5225<br>http://192.168.1.83:5225 | 企业微信登录 | 健康监控大屏主应用 |
| **Grafana** | http://localhost:3001 | admin / admin123 | 监控可视化面板 |
| **Prometheus** | http://localhost:9091 | 无需登录 | 指标采集和查询 |
| **Alertmanager** | http://localhost:9094 | 无需登录 | 告警管理系统 |
### 数据库连接
**MySQL**
```bash
Host: 127.0.0.1
Port: 3306
Database: test
Username: root
Password: 123456
```
**Redis**
```bash
Host: 127.0.0.1 或 192.168.1.6
Port: 6379
Password: (无密码)
```
### 监控系统
完整的监控系统文档和凭证信息,请查看:
📄 [monitoring/README.md](monitoring/README.md) - 包含所有监控组件的详细配置和访问凭证
**快速启动监控系统:**
```bash
cd monitoring
docker-compose up -d
```
### 安全提示
⚠️ **生产环境部署前请务必修改所有默认密码!**
- Grafana:首次登录后立即修改 admin 密码
- MySQL:创建专用应用账户,限制权限范围
- Redis:启用密码认证,配置强密码
- 监控服务:仅在内网访问,禁止公网暴露
## 🆕 最新更新 v1.3.5
### 🎯 个人大屏UI现代化改造
+82 -2
View File
@@ -13,6 +13,80 @@
| Grafana | 3001 | 可视化面板 | http://localhost:3001 |
| Node Exporter | 9101 | 系统指标导出 | http://localhost:9101 |
## 🔐 系统凭证
### 监控系统
**Grafana**
- URL: http://localhost:3001
- 用户名: `admin`
- 密码: `admin123`
- 说明: 首次登录后可以修改密码
**Prometheus**
- URL: http://localhost:9091
- 认证: 无需登录(仅内网访问)
**Alertmanager**
- URL: http://localhost:9094
- 认证: 无需登录(仅内网访问)
**Loki**
- URL: http://localhost:3100
- 认证: 无需登录(仅内网访问)
### ljwx-bigscreen 应用
**Web界面**
- URL: http://localhost:5225 或 http://192.168.1.83:5225
- 认证: 根据组织配置(使用企业微信或用户名密码登录)
**指标端点**
- URL: http://localhost:5225/metrics
- 认证: 无需认证(供Prometheus采集)
### 数据库连接信息
**MySQL**
- 主机: 127.0.0.1
- 端口: 3306
- 数据库: test
- 用户名: root
- 密码: 123456
- 说明: ljwx-bigscreen后端数据库
**Redis**
- 主机: 127.0.0.1 或 192.168.1.6
- 端口: 6379
- 密码: (无密码)
- 说明: 缓存和实时数据
### 企业微信配置
**应用凭证** (配置在环境变量中)
- AppID: `WECHAT_APP_ID`
- AppSecret: `WECHAT_APP_SECRET`
- 说明: 用于告警通知和用户认证
### Docker Registry (如需要)
**Aliyun容器镜像服务**
- Registry: registry.cn-hangzhou.aliyuncs.com/your-namespace
- 用户名: 阿里云账号
- 密码: 访问凭证
- 说明: 多架构镜像仓库
### 安全建议
⚠️ **重要提示**:
1. **生产环境**: 务必修改所有默认密码
2. **Grafana**: 首次登录后立即修改admin密码
3. **MySQL**: 为生产环境创建独立用户,限制权限
4. **Redis**: 生产环境启用密码认证
5. **网络隔离**: 监控服务仅在内网访问,禁止公网暴露
6. **企业微信**: 妥善保管AppSecret,不要提交到代码仓库
7. **定期更新**: 定期轮换数据库密码和API密钥
## 🚀 快速开始
### 1. 启动监控系统
@@ -36,17 +110,23 @@ docker-compose logs -f
**Grafana 仪表板**
- URL: http://localhost:3001
- 默认用户名: `admin`
- 默认密码: `admin123`
- 登录凭证: 见上方"系统凭证"章节
- 功能: 可视化面板、数据源管理、告警配置
**Prometheus**
- URL: http://localhost:9091
- 查看指标: http://localhost:9091/graph
- 查看告警: http://localhost:9091/alerts
- 查看采集目标: http://localhost:9091/targets
**Alertmanager**
- URL: http://localhost:9094
- 查看告警: http://localhost:9094/#/alerts
- 查看配置: http://localhost:9094/#/status
**Loki**
- URL: http://localhost:3100
- 通过Grafana Explore访问: http://localhost:3001/explore
## 📊 Grafana 配置