Repository navigation
fix(docker): 统一认证并锁定 OpenCode 构建与运行版本 - #195
Open
ql0202cocou wants to merge 5 commits into
Open
ql0202cocou wants to merge 5 commits into
ql0202cocou wants to merge 5 commits into
Conversation
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
仅设置
OPENCODE_PASSWORD时,后端启用认证,但网关仍读取旧变量,导致预览管理接口按空密码放行。本 PR 统一两端认证,并固定 OpenCode 的构建及运行版本。OPENCODE_PASSWORD,否则回退OPENCODE_SERVER_PASSWORD,完整 Compose 部署的用户名统一为opencode。两种密码均为空时,网关和后端容器拒绝启动。docker compose config仅展开变量,空密码由容器入口和独立路由进程拒绝;独立网关/路由进程同时拒绝空用户名,认证检查也拒绝空凭据。部署时必须设置非空密码;旧密码变量仍兼容,完整 Compose 部署不再使用旧的自定义用户名。独立运行 gateway 或路由进程时,必须提供非空的
ROUTER_USERNAME和ROUTER_PASSWORD。升级 OpenCode 需更新后端镜像。README 和环境变量示例已同步。验证:
cargo check --locked --offline、cargo fmt --check、Shell 语法、actionlint 和git diff --check通过。