Skip to content

Commit 724fb2a

Browse files
committed
Auto-detect Linux desktop session env
1 parent a054fdb commit 724fb2a

18 files changed

Lines changed: 560 additions & 20 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ open-computer-use call list_apps
107107
open-computer-use call --calls '[{"tool":"get_app_state","args":{"app":"gnome-text-editor"}},{"tool":"type_text","args":{"app":"gnome-text-editor","text":"hello"}}]'
108108
```
109109

110-
The process needs the desktop user's `XDG_RUNTIME_DIR`, `DBUS_SESSION_BUS_ADDRESS`, and display environment. A pure SSH tty without those variables can build and launch the binary, but it cannot inspect or operate the GUI session. Screenshot capture is best-effort on GNOME Wayland and may be omitted when the compositor returns a black frame.
110+
The runtime needs the desktop user's D-Bus and display session. When those variables are missing, it tries to discover the current user's signed-in desktop session at launch from `/run/user/<uid>` and common desktop processes, so the normal Codex setup remains `npm i -g open-computer-use`, `open-computer-use install-codex-mcp`, then restart Codex from the same desktop user. A pure SSH tty without a discoverable signed-in desktop session can build and launch the binary, but it cannot inspect or operate the GUI session. Screenshot capture is best-effort on GNOME Wayland and may be omitted when the compositor returns a black frame.
111111

112112
## Cursor Motion
113113

README.zh-CN.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ open-computer-use call list_apps
117117
open-computer-use call --calls '[{"tool":"get_app_state","args":{"app":"gnome-text-editor"}},{"tool":"type_text","args":{"app":"gnome-text-editor","text":"hello"}}]'
118118
```
119119

120-
这个进程需要桌面用户的 `XDG_RUNTIME_DIR``DBUS_SESSION_BUS_ADDRESS` 和 display 环境。纯 SSH tty 可以构建和启动二进制,但不能直接 inspect 或操作 GUI session。GNOME Wayland 下截图是 best-effort,如果 compositor 返回黑图,Linux bridge 会省略 image block。
120+
runtime 需要桌面用户的 D-Bus 和 display session。缺少这些变量时,它会在启动时尝试从 `/run/user/<uid>` 和常见桌面进程自动发现当前用户已登录的桌面 session,所以 Codex 的正常接入路径仍然是 `npm i -g open-computer-use``open-computer-use install-codex-mcp`,然后用同一个桌面用户重启 Codex。纯 SSH tty 如果找不到已登录桌面 session,可以构建和启动二进制,但不能直接 inspect 或操作 GUI session。GNOME Wayland 下截图是 best-effort,如果 compositor 返回黑图,Linux bridge 会省略 image block。
121121

122122
## Cursor Motion
123123

0 commit comments

Comments
 (0)