36 lines
1.1 KiB
Markdown
36 lines
1.1 KiB
Markdown
# 2026-06-09 — 服务器原生 RDP 启动
|
||
|
||
## 摘要
|
||
|
||
为 Windows 子机增加「下载 .rdp、本机 mstsc 直连」能力;**不**引入 JWT 短票、WebSocket 隧道或 RDP 连接审计。
|
||
|
||
## 动机
|
||
|
||
运维需要远程桌面,但不需要复用 WebSSH 的鉴权与代理栈;本机远程桌面客户端即可满足。
|
||
|
||
## 涉及文件
|
||
|
||
- `docs/design/specs/2026-06-09-rdp-native-launch-design.md`
|
||
- `server/utils/rdp_config.py`
|
||
- `server/api/schemas.py` — `rdp_enabled` / `rdp_port` / `rdp_username`
|
||
- `server/api/servers.py` — `GET /api/servers/{id}/rdp-file`、列表字段
|
||
- `frontend/src/composables/servers/useServerFormDialog.ts`
|
||
- `frontend/src/components/servers/ServerFormDialog.vue`
|
||
- `frontend/src/pages/ServersPage.vue`
|
||
- `frontend/src/api/index.ts` — `downloadGet`
|
||
- `tests/test_rdp_config.py`
|
||
|
||
## 迁移 / 重启
|
||
|
||
- 无 DB 迁移(配置存 `extra_attrs`)
|
||
- 后端需重启;前端需 `vite build` 后同步 `web/app/`
|
||
|
||
## 验证
|
||
|
||
```bash
|
||
pytest tests/test_rdp_config.py -q
|
||
cd frontend && npm run type-check
|
||
```
|
||
|
||
浏览器:编辑服务器启用 RDP → 列表点「RDP」→ 下载 `.rdp` 含正确地址与用户名。
|