Why does OpenCode start in serve mode, and after the OpenCode CLI connects to this serve mode, it can only access files within the directory from which the serve mode was launched? #7272

Open
opened 2026-02-16 18:06:39 -05:00 by yindo · 1 comment
Owner

Originally created by @BeliveLove on GitHub (Jan 22, 2026).

Originally assigned to: @thdxr on GitHub.

Description

Why does OpenCode start in serve mode, and after the OpenCode CLI connects to this serve mode, it can only access files within the directory from which the serve mode was launched?

Plugins

No response

OpenCode version

No response

Steps to reproduce

No response

Screenshot and/or share link

No response

Operating System

No response

Terminal

No response

Originally created by @BeliveLove on GitHub (Jan 22, 2026). Originally assigned to: @thdxr on GitHub. ### Description Why does OpenCode start in serve mode, and after the OpenCode CLI connects to this serve mode, it can only access files within the directory from which the serve mode was launched? ### Plugins _No response_ ### OpenCode version _No response_ ### Steps to reproduce _No response_ ### Screenshot and/or share link _No response_ ### Operating System _No response_ ### Terminal _No response_
yindo added the bug label 2026-02-16 18:06:39 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Jan 22, 2026):

This issue might be a duplicate of existing issues. Please check:

  • #4686: TUI sends absolute local paths causing ENOENT on server side (related to file path resolution issues when connecting to remote serve instances)
  • #9077: Can't run tools in OpenCode Desktop - tools executed from / instead of project cwd (related to working directory scope issues in server/client architecture)
  • #2177: Allow explicitly changing working directory (related to working directory restriction issues)

Feel free to ignore if none of these address your specific case.

@github-actions[bot] commented on GitHub (Jan 22, 2026): This issue might be a duplicate of existing issues. Please check: - #4686: TUI sends absolute local paths causing ENOENT on server side (related to file path resolution issues when connecting to remote serve instances) - #9077: Can't run tools in OpenCode Desktop - tools executed from / instead of project cwd (related to working directory scope issues in server/client architecture) - #2177: Allow explicitly changing working directory (related to working directory restriction issues) Feel free to ignore if none of these address your specific case.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#7272