Commit Graph
4 Commits
Author SHA1 Message Date
nesquena-hermesandhappy5318 94539cf074 docs(zh): correct the .env precedence note for start.ps1
The new "改完密码先验证一下" note said start.sh, start.ps1 and bootstrap.py all let
repo-.env values override an inline HERMES_WEBUI_PASSWORD. That holds for start.sh
(`set -a; source .env` runs before anything else), but start.ps1 skips any .env key that
is already set in the environment (start.ps1:70-72), so on native Windows the
`$env:HERMES_WEBUI_PASSWORD` shown in this section wins. start.ps1 runs server.py
directly, so the suggested HERMES_WEBUI_PRESERVE_ENV=1 did not apply to it either.

Keep the useful advice (check the login page actually asks for the new password, and
look for a stale value in .env), state the correct precedence for each launcher, and
drop the PRESERVE_ENV suggestion.

Co-authored-by: happy5318 <34227488+happy5318@users.noreply.github.com>
2026-09-26 05:01:24 +00:00
happy5318 c13a2ecf64 docs(zh): align Windows sections with start.ps1 / WSL-only autostart
Review feedback (nesquena 9/24, PR #7814):

1. §三.1 "首次准备" 原本让用户在 WebUI 仓库本地 `python -m venv venv`
   再 `pip install -r requirements.txt`,但 `start.ps1`(line 132-136)
   启动时优先用 `<hermes-agent>\venv\Scripts\python.exe`,找不到才
   回退到 PATH 上的 `python`——WebUI 本地的 venv 永远不会被它挑中。
   照原指南装的依赖会变成死代码,启动时仍然缺包。重写为:要求把
   requirements.txt 装进 hermes-agent 的 venv,列出 hermes-agent 的
   常见安装位置,保留 WebUI 本地 venv 作备选但明确警告。

2. §三.4 之前是 "Windows 开机自启",但内容(setup_webui_autostart.ps1
   → wsl.exe → scripts/wsl/hermes_webui_autostart.sh)实际上**只**
   启动 WSL 里的 WebUI,放在 native-Windows 章节里会误导用户以为
   native 启动也有自启配套。把它从 §三 抽出,单独成节
   "## 四、WSL 用户:Windows 开机自启",顶部加 WSL-only 提示,
   §四/§五 顺延为 §五/§六,FAQ 里的 cross-ref 同步更新,README
   中文链接文案改为 "...Windows 原生部署(自启仅适用 WSL 用户)"
   不再暗示 native 自启。

3. 顺手处理两条可选小项:

   a. start.sh / start.ps1 / bootstrap.py 都会从仓库 .env 加载
      `HERMES_WEBUI_PASSWORD`,且 .env 里的值**覆盖**命令行内联
      的 env var。在 §三.2 加 callout 提示:改完密码后打开登录页
      确认真的要求输入密码;如未生效就清 .env 或显式
      `HERMES_WEBUI_PRESERVE_ENV=1`。

   b. §六.1 "Tailscale 私有" 原写法 "仅你的 tailnet 设备可达" 在
      方案 B(`HERMES_WEBUI_HOST=0.0.0.0`)下不成立——`0.0.0.0`
      绑的是所有接口,"仅 tailnet" 完全靠防火墙那条
      `100.64.0.0/10` 规则兜底。改为:首选 `HERMES_WEBUI_HOST=
      $(tailscale ip -4)`(只绑 Tailscale 网卡,更严),次选
      `0.0.0.0` + 防火墙,并明确标注"防火墙被改/被关就立刻
      对 LAN/公网开放"。

保留 24dd1fbd 的 public-exposure note 修正。
2026-09-26 01:39:24 +08:00
nesquena-hermes 24dd1fbd58 docs(zh): correct the public-exposure note (WebUI does rate-limit logins; the gap is plaintext HTTP) 2026-09-24 19:47:45 +00:00
xiaobao a77956fcfd docs(zh): add Chinese remote-access guide (Tailscale, SSH tunnel, native Windows)
Companion to docs/remote-access.md for Chinese users, per the
contribution shape requested in #7393:

- Tailscale Serve preferred path (loopback + HTTPS MagicDNS), direct
  tailnet IP as fallback, SSH tunnel section
- Native Windows deployment via the official start.ps1 launcher with
  password auth; firewall rule scoped to the Tailscale CGNAT range
  (100.64.0.0/10) instead of an all-interfaces open
- Windows logon auto-start via the official
  scripts/windows/setup_webui_autostart.ps1 scheduled-task helper
- Explicit security boundary section distinguishing tailnet-private,
  LAN, and public exposure
- No machine-specific usernames/drives/model choices/popularity numbers
- Linked from the README docs index

Tests: test_readme_compat_section, test_issue3012_3006_docker_docs,
test_nix_flake_module_source all pass (17/17).
2026-09-25 02:37:52 +08:00