feat(controller): add HICLAW_DM_POLICY env var for configurable Matri…#943
Open
hoshn wants to merge 2 commits into
Open
feat(controller): add HICLAW_DM_POLICY env var for configurable Matri…#943hoshn wants to merge 2 commits into
hoshn wants to merge 2 commits into
Conversation
…x DM policy Introduce runtime control over dm.policy in generated openclaw.json. Default "allowlist" preserves existing behavior; "open" allows any user to DM workers with per-room session isolation. Includes Helm support via controller.dmPolicy value.
Contributor
📊 CI Metrics ReportSummary
By Role
Per-Test Breakdown
Trends✅ 1 test(s) improved (fewer LLM calls) Generated by HiClaw CI on 2026-06-30 08:22:44 UTC |
Author
|
你好, 我们在实际部署中发现,hiclaw-controller 为 Worker/Manager 生成 openclaw.json 时,channels.matrix.dm.policy 被硬编码为 "allowlist",allowFrom 仅限 Manager/Admin(或团队领导): 这导致外部 Matrix 用户(如业务系统接入方、终端客户)无法直接私聊 Worker,限制了 DM 通道在开放场景下的使用。运维人员无法通过环境变量或 Helm values 在部署时调整此策略,只能 fork 源码修改后重新构建。 本 PR 的解决方案:
向后兼容: 不设置 HICLAW_DM_POLICY 时,生成的 openclaw.json 与原代码完全一致,默认行为无任何变化。 请审核,谢谢! |
2 tasks
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.
feat(controller): add HICLAW_DM_POLICY env var for configurable Matrix DM policy
Introduce runtime control over dm.policy in generated openclaw.json.
Default "allowlist" preserves existing behavior; "open" allows any user
to DM workers with per-room session isolation. Includes Helm support
via controller.dmPolicy value.
feat(controller): 支持通过 HICLAW_DM_POLICY 环境变量配置 Matrix DM 策略
此前 dm.policy 硬编码为 "allowlist",仅允许 Manager/Admin(或团队领导)
发起 DM。本次新增运行时环境变量 HICLAW_DM_POLICY,运维人员可在不改源码
的情况下将策略切换为 "open"。
改动内容:
向后兼容:不设置 HICLAW_DM_POLICY 时,生成的 openclaw.json 与改动前完全一致。
Helm 使用方式:
controller:
dmPolicy: "open"
feat(controller): add HICLAW_DM_POLICY env var for configurable Matrix DM policy
Introduce runtime control over dm.policy in generated openclaw.json.
Default "allowlist" preserves existing behavior; "open" allows any user
to DM workers with per-room session isolation. Includes Helm support
via controller.dmPolicy value.
feat(controller): supports configuring Matrix DM policy through HICLAW_DM_POLICY environment variable
Previously dm.policy was hardcoded to "allowlist", allowing only Manager/Admin (or team leaders)
Start a DM. This time, the runtime environment variable HICLAW_DM_POLICY is added, so operation and maintenance personnel can use it without changing the source code.
Switch the policy to "open".
Changes:
Backward compatibility: When HICLAW_DM_POLICY is not set, the generated openclaw.json is exactly the same as before the change.
How to use Helm:
controller:
dmPolicy: "open"