codeg icon indicating copy to clipboard operation
codeg copied to clipboard

|Feature Request| Decouple Codeg server hosting from ACP agent execution and workspace filesystem.

Open Klektic opened this issue 3 weeks ago • 1 comments

Allow Codeg's server to run on one machine while ACP agents execute on another machine with access to that machine's local workspaces.

Currently, custom ACP launch commands can start remote agents, but Codeg still resolves working directories against the server's local filesystem. This prevents remote agents from using their own host's workspace paths.

Ideally the setup would allow for a separate execution host for ACP agents, directories, and workspace passes on the execution host rather than wherever the code G server is residing. All the usual life cycle operations, of course, are allowing you to preserve conversation history and session management on a central server. That would allow for different operating systems and file system conventions between servers and wherever the agents are being hosted for execution.

being able to access your conversation history and possibly other work environments, Even if those other environments are not the same operating system or work environment as the server, would ideal.

Klektic avatar Nov 09 '26 03:11 Klektic

Implementation progress: Linux-hosted Codeg with Windows-hosted agents

I've been prototyping this architecture with a Raspberry Pi 5 hosting Codeg and a Windows workstation handling agent execution, inference, and project files.

The goal is to keep Codeg's server, conversations, and session management available independently of the Windows workstation, while preserving native Windows execution and filesystem access.

Approach

The prototype uses:

  1. Codeg server on Linux for the UI, conversation history, and session management.
  2. ACP over SSH to launch and communicate with agents running on Windows.
  3. A companion MCP bridge that connects Windows-hosted agents back to Codeg's Linux-local MCP broker through SSH.
  4. Native Windows execution for agent commands and project-file operations, without copying or mounting Windows workspaces on Linux.

The MCP bridge is important because Codeg's companion normally expects access to server-local IPC. Simply launching the agent remotely doesn't solve that dependency.

Implementation details

The bridge uses an external ACP launch shim to redirect the companion connection through SSH while preserving Codeg's connection metadata and authentication parameters.

The Windows agent continues using its existing local tools, project paths, and model provider. Codeg remains responsible for conversation and session management.

Testing completed

The prototype has passed targeted tests covering:

  • ACP communication over SSH.
  • Companion MCP initialization and tool discovery.
  • Communication with the actual Codeg MCP broker.
  • Session information and same-session reconnection.
  • Selected feedback and task operations.
  • Windows-native file and command execution.
  • Connection recovery and cleanup behavior.

Remaining limitations

This is not yet a completed production migration.

The remaining work includes validating the full model-driven workflow under the intended production permissions, ensuring reliable startup after a Pi reboot, and completing the server-data migration.

There is also a distinction between using native Windows file/command tools and Codeg-managed delegation. The current configuration does not provide every feature simultaneously.

What native support would improve

The workaround demonstrates that remote agent execution is feasible, but requires custom bridging and lifecycle management.

Native Codeg support could eliminate much of that complexity by separating:

  • Server host
  • Agent execution host
  • Workspace filesystem host

Ideally, Codeg would let users select a remote execution host, resolve workspace paths on that host, and manage agent lifecycle and companion communication without requiring custom SSH wrappers.

This would make an always-on Linux Codeg server with Windows-hosted agents practical for users who don't want to move their development environments or maintain a separate copy of their projects.

Klektic avatar Nov 11 '26 05:11 Klektic